From eb32eccea9966d0dc94c3e8167e04c4245fde827 Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Sat, 16 Feb 2019 17:57:23 -0500 Subject: [PATCH 01/10] Remove String utilities in favor of those defined in accent4j (#356) * Replace Strings utils in favor of those from accent4j - Remove Strings.java - Remove StringSplitter framework These two things were redefined in accent4j, so we're now using thosr * add notes to unit tests * update changelog * Fix formatting * rename StringsTest to AnyStringsTest * Add deleted classes back * fix formatting * fix failing unit test * javadoc comment --- CHANGELOG.md | 2 + build.gradle | 2 +- .../java/com/cinchapi/concourse/Link.java | 4 +- .../com/cinchapi/concourse/lang/Language.java | 6 +- .../com/cinchapi/concourse/util/Convert.java | 20 +- .../util/QuoteAwareStringSplitter.java | 3 + .../cinchapi/concourse/util/SplitOption.java | 1 + .../concourse/util/StringSplitter.java | 2 + .../com/cinchapi/concourse/util/Strings.java | 367 ++---------------- .../{StringsTest.java => AnyStringsTest.java} | 129 +++--- .../cinchapi/concourse/util/ConvertTest.java | 9 +- .../util/QuoteAwareStringSplitterTest.java | 199 ---------- .../util/StringSplitterPerformanceTest.java | 9 +- .../concourse/util/StringSplitterTest.java | 15 +- .../server/ManagedConcourseServer.java | 4 +- .../concourse/importer/LineBasedImporter.java | 12 +- .../concourse/importer/cli/ImportCli.java | 10 +- .../com/cinchapi/concourse/InsertTest.java | 4 +- .../concourse/importer/ResolveKeyTest.java | 4 +- .../concourse/shell/ConcourseShellTest.java | 4 +- .../server/plugin/io/MessageQueue.java | 6 +- .../server/plugin/io/SharedMemory.java | 4 +- .../server/plugin/util/Versions.java | 4 +- .../server/plugin/util/VersionsTest.java | 10 +- .../concourse/server/ConcourseServer.java | 17 +- .../server/cli/plugin/InstallPluginCli.java | 21 +- .../server/http/EndpointContainer.java | 14 +- .../concourse/server/http/RoutingKey.java | 6 +- .../http/webserver/ConcourseHttpHandler.java | 4 +- .../concourse/server/ops/Operations.java | 2 +- .../server/plugin/PluginManager.java | 6 +- .../concourse/server/storage/Engine.java | 4 +- .../concourse/server/storage/Stores.java | 4 +- .../com/cinchapi/concourse/util/Commands.java | 2 + .../com/cinchapi/concourse/util/TStrings.java | 4 +- .../server/http/EndpointContainerTest.java | 4 +- .../cinchapi/concourse/util/TMapsTest.java | 7 +- .../concourse/shell/ConcourseShell.java | 4 +- 38 files changed, 219 insertions(+), 710 deletions(-) rename concourse-driver-java/src/test/java/com/cinchapi/concourse/util/{StringsTest.java => AnyStringsTest.java} (68%) delete mode 100644 concourse-driver-java/src/test/java/com/cinchapi/concourse/util/QuoteAwareStringSplitterTest.java diff --git a/CHANGELOG.md b/CHANGELOG.md index 990599b219..c45c09f976 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,8 @@ * Added the `com.cinchapi.concourse.etl` package that contains data processing utilities: * A `Strainer` can be used to process a `Map` using Concourse's data model rules. In particular, the `Strainer` encapsulates logic to break down top-level sequence values and process their elements individually. * The `Transform` class contains functions for common data transformations. +* Removed the `Strings` utility class in favor of `AnyStrings` from `accent4j`. +* Removed the `StringSplitter` framework in favor of the same from `accent4j`. #### Version 0.9.6 (TBD) * Fixed a bug that caused a `ParseException` to be thrown when trying to use a `Criteria` object containing a string value wrapped in single or double quotes out of necessity (i.e. because the value contained a keyword). This bug happened because the wrapping quotes were dropped by Concourse Server when parsing the `Criteria`. diff --git a/build.gradle b/build.gradle index aae860a0dd..1da84dc0d0 100644 --- a/build.gradle +++ b/build.gradle @@ -109,7 +109,7 @@ subprojects { compile 'joda-time:joda-time:2.2' compile 'org.apache.thrift:libthrift:0.9.3' compile 'commons-configuration:commons-configuration:1.9' - compile group: 'com.cinchapi', name: 'accent4j', version: '1.5.2', changing:true + compile group: 'com.cinchapi', name: 'accent4j', version: '1.5.3', changing:true compile 'com.cinchapi:lib-config:1.3.1' testCompile 'junit:junit:4.11' diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java index 78912c9ed5..3bdf08261e 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java @@ -17,10 +17,10 @@ import javax.annotation.concurrent.Immutable; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.lang.BuildableState; import com.cinchapi.concourse.lang.Criteria; import com.cinchapi.concourse.util.Convert; -import com.cinchapi.concourse.util.Strings; import com.google.common.base.Preconditions; import com.google.common.primitives.Longs; import com.google.common.primitives.UnsignedLongs; @@ -141,7 +141,7 @@ public static String toWhere(Criteria criteria) { */ public static String toWhere(Object criteria) { Preconditions.checkArgument(criteria instanceof BuildableState, - Strings.format("{} is not a valid criteria", criteria)); + AnyStrings.format("{} is not a valid criteria", criteria)); return toWhere(((BuildableState) criteria).build()); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java index b1624eab63..fc41344e3d 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java @@ -25,11 +25,11 @@ import com.cinchapi.ccl.grammar.Symbol; import com.cinchapi.ccl.grammar.TimestampSymbol; import com.cinchapi.ccl.grammar.ValueSymbol; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.thrift.TCriteria; import com.cinchapi.concourse.thrift.TSymbol; import com.cinchapi.concourse.thrift.TSymbolType; import com.cinchapi.concourse.util.Convert; -import com.cinchapi.concourse.util.Strings; import com.google.common.collect.Lists; /** @@ -55,12 +55,12 @@ else if(tsymbol.getType() == TSymbolType.KEY) { else if(tsymbol.getType() == TSymbolType.VALUE) { Object symbol = Convert.stringToJava(tsymbol.getSymbol()); if(symbol instanceof String && !symbol.equals(tsymbol.getSymbol()) - && Strings.isWithinQuotes(tsymbol.getSymbol())) { + && AnyStrings.isWithinQuotes(tsymbol.getSymbol())) { // CON-634: This is an obscure corner case where the surrounding // quotes on the original tsymbol were necessary to escape a // keyword, but got dropped because of the logic in // Convert#stringToJava - symbol = Strings.ensureWithinQuotes(symbol.toString()); + symbol = AnyStrings.ensureWithinQuotes(symbol.toString()); } return new ValueSymbol(symbol); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Convert.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Convert.java index 67c1a079ee..24902fab8c 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Convert.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Convert.java @@ -33,6 +33,7 @@ import org.joda.time.format.DateTimeFormatter; import com.cinchapi.ccl.util.NaturalLanguage; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.concourse.Concourse; import com.cinchapi.concourse.Link; @@ -142,6 +143,11 @@ public final class Convert { private static final Pattern STRING_RESOLVABLE_LINK_REGEX = Pattern .compile("^@(?=.*[ ]).+@$"); + /** + * The character that indicates a String should be treated as a {@link Tag}. + */ + private static final char TAG_MARKER = '`'; + /** * Takes a JSON string representation of an object or an array of JSON * objects and returns a list of {@link Multimap multimaps} with the @@ -455,7 +461,7 @@ public static Object stringToJava(String value) { char first = value.charAt(0); char last = value.charAt(value.length() - 1); Long record; - if(Strings.isWithinQuotes(value)) { + if(AnyStrings.isWithinQuotes(value, TAG_MARKER)) { // keep value as string since its between single or double quotes return value.substring(1, value.length() - 1); } @@ -475,7 +481,7 @@ else if(value.equalsIgnoreCase("true")) { else if(value.equalsIgnoreCase("false")) { return false; } - else if(first == '`' && last == '`') { + else if(first == TAG_MARKER && last == TAG_MARKER) { return Tag.create(value.substring(1, value.length() - 1)); } else if(first == '|' && last == '|') { @@ -503,7 +509,7 @@ else if(first == '|' && last == '|') { return timestamp; } else { - return MoreObjects.firstNonNull(Strings.tryParseNumber(value), + return MoreObjects.firstNonNull(AnyStrings.tryParseNumber(value), value); } } @@ -555,7 +561,7 @@ public static Operator stringToOperator(String symbol) { * @return An instruction to create a {@link ResolvableLink} */ public static String stringToResolvableLinkInstruction(String ccl) { - return Strings.joinSimple(RAW_RESOLVABLE_LINK_SYMBOL_PREPEND, ccl, + return AnyStrings.joinSimple(RAW_RESOLVABLE_LINK_SYMBOL_PREPEND, ccl, RAW_RESOLVABLE_LINK_SYMBOL_APPEND); } @@ -586,7 +592,7 @@ public static String stringToResolvableLinkInstruction(String ccl) { public static String stringToResolvableLinkSpecification(String key, String rawValue) { return stringToResolvableLinkInstruction( - Strings.joinWithSpace(key, "=", rawValue)); + AnyStrings.joinWithSpace(key, "=", rawValue)); } /** @@ -881,8 +887,8 @@ public Object getValue() { @Override public String toString() { - return Strings.format("{} for {}", this.getClass().getSimpleName(), - ccl); + return AnyStrings.format("{} for {}", + this.getClass().getSimpleName(), ccl); } } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java index 9c558b2714..f41f5bf4b2 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java @@ -20,7 +20,10 @@ * between single or double quotes * * @author Jeff Nelson + * @deprecated use {@link com.cinchapi.common.base.QuoteAwareStringSplitter} + * instead */ +@Deprecated public class QuoteAwareStringSplitter extends StringSplitter { /** diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java index a9098090b6..20a6e3e43b 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java @@ -22,6 +22,7 @@ * * @author Jeff Nelson */ +@Deprecated public enum SplitOption { /** * Split on a newline character sequence (\n, \r\n, \r) in addition to diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java index 2cd2a81ba7..72b80e1831 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java @@ -45,7 +45,9 @@ *

* * @author Jeff Nelson + * @deprecated use {@link com.cinchapi.common.base.StringSplitter} instead */ +@Deprecated public class StringSplitter { /** diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java index 4611435e6b..e96d03c9f3 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java @@ -20,16 +20,7 @@ import javax.annotation.Nullable; -import org.slf4j.helpers.MessageFormatter; - -import com.cinchapi.common.base.Characters; -import com.google.common.base.MoreObjects; -import com.google.common.collect.Lists; -import com.google.common.collect.Sets; -import com.google.common.primitives.Doubles; -import com.google.common.primitives.Floats; -import com.google.common.primitives.Ints; -import com.google.common.primitives.Longs; +import com.cinchapi.common.base.AnyStrings; import com.google.gson.JsonParseException; /** @@ -37,7 +28,9 @@ * functionality or optimize existing ones. * * @author Jeff Nelson + * @deprecated in version 0.9.6; use {@link AnyStrings} instead */ +@Deprecated public final class Strings { /** @@ -53,12 +46,7 @@ public final class Strings { * {@code string} */ public static String ensureEndsWith(String string, String suffix) { - if(string.endsWith(suffix)) { - return string; - } - else { - return joinSimple(string, suffix); - } + return AnyStrings.ensureEndsWith(string, suffix); } /** @@ -74,12 +62,7 @@ public static String ensureEndsWith(String string, String suffix) { * {@code string} */ public static String ensureStartsWith(String string, String prefix) { - if(string.startsWith(prefix)) { - return string; - } - else { - return joinSimple(prefix, string); - } + return AnyStrings.ensureStartsWith(string, prefix); } /** @@ -96,7 +79,7 @@ public static String ensureStartsWith(String string, String prefix) { * not already */ public static String ensureWithinQuotes(String string) { - return isWithinQuotes(string) ? string : joinSimple("\"", string, "\""); + return AnyStrings.ensureWithinQuotes(string); } /** @@ -131,41 +114,7 @@ public static String ensureWithinQuotes(String string) { */ public static String ensureWithinQuotesIfNeeded(String string, char delimiter) { - boolean foundDouble = false; - boolean foundSingle = false; - boolean foundDelimiter = false; - StringBuilder escaped = new StringBuilder(); - escaped.append('"'); - if(!isWithinQuotes(string)) { - char[] chars = string.toCharArray(); - for (int i = 0; i < chars.length; ++i) { - char c = chars[i]; - if(c == delimiter) { - foundDelimiter = true; - } - else if(c == '"') { - foundDouble = true; - escaped.append('\\'); - } - else if(c == '\'') { - foundSingle = true; - } - escaped.append(c); - } - escaped.append('"'); - if(foundDelimiter) { - if(foundDouble && foundSingle) { - return escaped.toString(); - } - else if(foundDouble) { - return Strings.format("'{}'", string); - } - else { // foundSingle or found no quotes - return Strings.format("\"{}\"", string); - } - } - } - return string; + return AnyStrings.ensureWithinQuotesIfNeeded(string, delimiter); } /** @@ -184,51 +133,7 @@ else if(foundDouble) { * @return the escaped {@code string} */ public static String escapeInner(String string, char... characters) { - char c = '\0'; - char pchar = '\0'; - StringBuilder sb = null; - Set chars = null; - if(characters.length == 1) { - c = characters[0]; - } - else { - chars = Sets.newHashSetWithExpectedSize(characters.length); - for (char ch : characters) { - chars.add(ch); - } - } - char[] schars = string.toCharArray(); - int offset = 0; - int i = 0; - while (i < schars.length) { - if(i > 0 && i < schars.length - 1) { - char schar = schars[i]; - if(pchar != '\\' && ((c != '\0' && c == schar) - || (chars != null && chars.contains(schar)))) { - sb = MoreObjects.firstNonNull(sb, new StringBuilder()); - sb.append(schars, offset, i - offset); - sb.append('\\'); - char escaped = Characters - .getEscapedCharOrNullLiteral(schar); - if(escaped != '0') { - sb.append(escaped); - } - else { - sb.append(schar); - } - offset = i + 1; - } - pchar = schar; - } - ++i; - } - if(sb != null) { - sb.append(schars, offset, i - offset); - return sb.toString(); - } - else { - return string; - } + return AnyStrings.escapeInner(string, characters); } /** @@ -245,31 +150,7 @@ public static String escapeInner(String string, char... characters) { * @return a {@link String} free of confusable unicode characters */ public static String replaceUnicodeConfusables(String string) { - char[] chars = string.toCharArray(); - for (int i = 0; i < chars.length; ++i) { - char c = chars[i]; - switch (c) { - default: - break; - case 'ʺ': - case '˝': - case 'ˮ': - case '˶': - case 'ײ': - case '״': - case '“': - case '”': - case '‟': - case '″': - case '‶': - case '〃': - case '"': - c = '"'; - break; - } - chars[i] = c; - } - return String.valueOf(chars); + return AnyStrings.replaceUnicodeConfusables(string); } /** @@ -292,7 +173,7 @@ public static String replaceUnicodeConfusables(String string) { * @return The formatted message */ public static String format(String pattern, Object... params) { - return MessageFormatter.arrayFormat(pattern, params).getMessage(); + return AnyStrings.format(pattern, params); } /** @@ -303,16 +184,7 @@ public static String format(String pattern, Object... params) { * @return the set of substrings */ public static Set getAllSubStrings(String string) { - Set result = Sets.newHashSet(); - for (int i = 0; i < string.length(); ++i) { - for (int j = i + 1; j <= string.length(); ++j) { - String substring = string.substring(i, j).trim(); - if(!com.google.common.base.Strings.isNullOrEmpty(substring)) { - result.add(substring); - } - } - } - return result; + return AnyStrings.getAllSubStrings(string); } /** @@ -324,45 +196,7 @@ public static Set getAllSubStrings(String string) { * @return {@code true} if {@code needle} is a substring */ public static boolean isSubString(String needle, String haystack) { - if(needle.length() > haystack.length()) { - return false; - } - else if(needle.length() == haystack.length()) { - return needle.equals(haystack); - } - else { - char[] n = needle.toCharArray(); - char[] h = haystack.toCharArray(); - int npos = 0; - int hpos = 0; - int stop = h.length - n.length; - int hstart = -1; - while (hpos < h.length && npos < n.length) { - char hi = h[hpos]; - char ni = n[npos]; - if(hi == ni) { - if(hstart == -1) { - hstart = hpos; - } - ++npos; - ++hpos; - } - else { - if(npos > 0) { - npos = 0; - hpos = hstart + 1; - hstart = -1; - } - else { - ++hpos; - } - if(hpos > stop) { - return false; - } - } - } - return npos == n.length; - } + return AnyStrings.isSubString(needle, haystack); } /** @@ -371,7 +205,10 @@ else if(needle.length() == haystack.length()) { * * @param json a json formatted string * @return {@code true} if the {@code json} is valid + * @deprecated in version 0.9.6; use + * {@link com.cinchapi.concourse.util.DataServices#jsonParser()#parse()} */ + @Deprecated public static boolean isValidJson(String json) { char first = json.charAt(0); char last = json.charAt(json.length() - 1); @@ -397,14 +234,7 @@ public static boolean isValidJson(String json) { * @return {@code true} if the string is between quotes */ public static boolean isWithinQuotes(String string) { - if(string.length() > 2) { - char first = string.charAt(0); - if(first == '"' || first == '\'') { - char last = string.charAt(string.length() - 1); - return first == last; - } - } - return false; + return AnyStrings.isWithinQuotes(string); } /** @@ -417,13 +247,7 @@ public static boolean isWithinQuotes(String string) { * @return the resulting String */ public static String join(char separator, Object... args) { - StringBuilder builder = new StringBuilder(); - for (int i = 0; i < args.length; ++i) { - builder.append(args[i]); - builder.append(separator); - } - builder.deleteCharAt(builder.length() - 1); - return builder.toString(); + return AnyStrings.join(separator, args); } /** @@ -436,13 +260,7 @@ public static String join(char separator, Object... args) { * @return the resulting String */ public static String join(String separator, Object... args) { - StringBuilder builder = new StringBuilder(); - for (int i = 0; i < args.length; ++i) { - builder.append(args[i]); - builder.append(separator); - } - builder.deleteCharAt(builder.length() - 1); - return builder.toString(); + return AnyStrings.join(separator, args); } /** @@ -453,11 +271,7 @@ public static String join(String separator, Object... args) { * @return the resulting String */ public static String joinSimple(Object... args) { - StringBuilder builder = new StringBuilder(); - for (int i = 0; i < args.length; ++i) { - builder.append(args[i]); - } - return builder.toString(); + return AnyStrings.joinSimple(args); } /** @@ -468,7 +282,7 @@ public static String joinSimple(Object... args) { * @return the resulting String */ public static String joinWithSpace(Object... args) { - return join(' ', args); + return AnyStrings.joinWithSpace(args); } /** @@ -482,7 +296,7 @@ public static String joinWithSpace(Object... args) { */ @Deprecated public static String[] splitButRespectQuotes(String string) { - return splitStringByDelimiterButRespectQuotes(string, " "); + return AnyStrings.splitButRespectQuotes(string); } /** @@ -506,21 +320,7 @@ public static String[] splitButRespectQuotes(String string) { * boundaries */ public static List splitCamelCase(String string) { - List words = Lists.newArrayList(); - char[] chars = string.toCharArray(); - StringBuilder word = new StringBuilder(); - for (int i = 0; i < chars.length; ++i) { - char c = chars[i]; - if(Character.isUpperCase(c) || c == '$') { - if(word.length() > 0) { - words.add(word.toString()); - } - word.setLength(0); - } - word.append(c); - } - words.add(word.toString()); - return words; + return AnyStrings.splitCamelCase(string); } /** @@ -538,13 +338,8 @@ public static List splitCamelCase(String string) { */ public static String[] splitStringByDelimiterButRespectQuotes(String string, String delimiter) { - // This is pretty inefficient: convert all single quotes to double - // quotes (except one off single quotes that are used as apostrophes) so - // the regex below works - string = string.replaceAll(" '", " \""); - string = string.replaceAll("' ", "\" "); - string = string.replaceAll("'$", "\""); - return string.split(delimiter + "(?=([^\"]*\"[^\"]*\")*[^\"]*$)"); + return AnyStrings.splitStringByDelimiterButRespectQuotes(string, + delimiter); } /** @@ -557,15 +352,7 @@ public static String[] splitStringByDelimiterButRespectQuotes(String string, * is not possible to parse the string into a boolean */ public static Boolean tryParseBoolean(String value) { - if(value.equalsIgnoreCase("true")) { - return true; - } - else if(value.equalsIgnoreCase("false")) { - return false; - } - else { - return null; - } + return AnyStrings.tryParseBoolean(value); } /** @@ -579,88 +366,7 @@ else if(value.equalsIgnoreCase("false")) { */ @Nullable public static Number tryParseNumber(String value) { - int size = value.length(); - if(value == null || size == 0) { - return null; - } - else if(value.charAt(0) == '0' && size > 1 && value.charAt(1) != '.') { - // Do not parse a string as a number if it has a leading 0 that is - // not followed by a decimal (i.e. 007) - return null; - } - boolean decimal = false; - boolean scientific = false; - for (int i = 0; i < size; ++i) { - char c = value.charAt(i); - if(!Character.isDigit(c)) { - if(i == 0 && c == '-' - || (scientific && (c == '-' || c == '+'))) { - continue; - } - else if(c == '.') { - if(!decimal && size > 1) { - decimal = true; - } - else { - // Since we've already seen a decimal, the appearance of - // another one suggests this is an IP address instead of - // a number - return null; - } - } - else if(i == size - 1 && c == 'D' && size > 1) { - // Respect the convention to coerce numeric strings to - // Double objects by appending a single 'D' character. - return Double.valueOf(value.substring(0, i)); - } - else if((c == 'E' || c == 'e') && i < size - 1) { - // CO-627: Account for valid representations of scientific - // notation - if(!scientific) { - scientific = true; - } - else { - // Since we've already seen a scientific notation - // indicator, another one suggests that this is not - // really a number - return null; - } - } - else { - return null; - } - } - } - try { - if(decimal || scientific) { - // Try to return a float (for space compactness) if it is - // possible to fit the entire decimal without any loss of - // precision. In order to do this, we have to compare the string - // output of both the parsed double and the parsed float. This - // is kind of inefficient, so substitute for a better way if it - // exists. - double d = Doubles.tryParse(value); - float f = Floats.tryParse(value); - if(String.valueOf(d).equals(String.valueOf(f))) { - return f; - } - else { - return d; - } - } - else if(value.equals("-")) { // CON-597 - return null; - } - else { - return MoreObjects.firstNonNull(Ints.tryParse(value), - Longs.tryParse(value)); - } - } - catch (NullPointerException e) { - throw new NumberFormatException(Strings.format( - "{} appears to be a number but cannot be parsed as such", - value)); - } + return AnyStrings.tryParseNumber(value); } /** @@ -675,16 +381,7 @@ else if(value.equals("-")) { // CON-597 */ @Nullable public static Number tryParseNumberStrict(String value) { - if(value == null || value.length() == 0) { - return null; - } - char last = value.charAt(value.length() - 1); - if(Character.isDigit(last)) { - return tryParseNumber(value); - } - else { - return null; - } + return AnyStrings.tryParseNumberStrict(value); } /** @@ -695,15 +392,7 @@ public static Number tryParseNumberStrict(String value) { * @return a string of length 1 containing the input char */ public static String valueOfCached(char c) { - if(c == '(') { - return "("; - } - else if(c == ')') { - return ")"; - } - else { - return String.valueOf(c); - } + return AnyStrings.valueOfCached(c); } private Strings() {/* noop */} diff --git a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringsTest.java b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/AnyStringsTest.java similarity index 68% rename from concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringsTest.java rename to concourse-driver-java/src/test/java/com/cinchapi/concourse/util/AnyStringsTest.java index 2561f21def..fb73ff4e05 100644 --- a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringsTest.java +++ b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/AnyStringsTest.java @@ -20,6 +20,7 @@ import org.junit.Assert; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.test.Variables; import com.google.common.collect.Lists; @@ -28,12 +29,16 @@ * * @author Jeff Nelson */ -public class StringsTest { +public class AnyStringsTest { + + // NOTE: This tests the AnyStrings utility class, which is defined in + // accent4j. The test is defined here (instead of that project) because it + // depends on some Concourse utilities @Test public void testSplitStringByDelimterAndRespectQuotes() { String string = "Sachin,,M,\"Maths,Science,English\",Need to improve in these subjects."; - String[] splitted = Strings + String[] splitted = AnyStrings .splitStringByDelimiterButRespectQuotes(string, ","); Assert.assertEquals( "[Sachin, , M, \"Maths,Science,English\", Need to improve in these subjects.]", @@ -43,7 +48,7 @@ public void testSplitStringByDelimterAndRespectQuotes() { @Test public void testSplitStringByDelimeterWithTrailiningSpaceAndRespectQuotes() { String string = "\"New Leaf, Same Page \""; - String[] splitted = Strings + String[] splitted = AnyStrings .splitStringByDelimiterButRespectQuotes(string, ","); Assert.assertEquals("[\"New Leaf, Same Page \"]", Arrays.toString(splitted)); @@ -53,7 +58,7 @@ public void testSplitStringByDelimeterWithTrailiningSpaceAndRespectQuotes() { @Test public void testSplitWithSingleQuotes() { String string = "John said 'hello world'"; - String[] toks = Strings.splitButRespectQuotes(string); + String[] toks = AnyStrings.splitButRespectQuotes(string); Assert.assertEquals( Lists.newArrayList("John", "said", "\"hello world\""), Lists.newArrayList(toks)); @@ -66,39 +71,39 @@ public void testTryParseValidNumber() { if(valid instanceof Double) { string += "D"; } - Assert.assertEquals(Strings.tryParseNumber(string), valid); + Assert.assertEquals(AnyStrings.tryParseNumber(string), valid); } @Test public void testTryParseInvalidNumber() { String invalid = Random.getStringNoDigits(); - Assert.assertNull(Strings.tryParseNumber(invalid)); + Assert.assertNull(AnyStrings.tryParseNumber(invalid)); } @Test public void testTryParseCoercedDouble() { Double d = Variables.register("double", Random.getDouble()); - Assert.assertEquals(d, Strings.tryParseNumber(d + "D")); + Assert.assertEquals(d, AnyStrings.tryParseNumber(d + "D")); } @Test public void testSplitCamelCase() { String str = "getArg1Arg2Arg3ABC"; Assert.assertEquals(Lists.newArrayList("get", "Arg1", "Arg2", "Arg3", - "A", "B", "C"), Strings.splitCamelCase(str)); + "A", "B", "C"), AnyStrings.splitCamelCase(str)); str = "testSplitCamelCase"; Assert.assertEquals( Lists.newArrayList("test", "Split", "Camel", "Case"), - Strings.splitCamelCase(str)); + AnyStrings.splitCamelCase(str)); str = "SplitCamelCase"; Assert.assertEquals(Lists.newArrayList("Split", "Camel", "Case"), - Strings.splitCamelCase(str)); + AnyStrings.splitCamelCase(str)); str = "Splitcamelcase"; Assert.assertEquals(Lists.newArrayList("Splitcamelcase"), - Strings.splitCamelCase(str)); + AnyStrings.splitCamelCase(str)); str = "splitcamelcase"; Assert.assertEquals(Lists.newArrayList("splitcamelcase"), - Strings.splitCamelCase(str)); + AnyStrings.splitCamelCase(str)); } @Test @@ -109,13 +114,13 @@ public void testFormat() { Object c = Random.getObject(); String expected = "This is a string " + a + " that needs to have " + b + " some random " + c + " substitution"; - String actual = Strings.format(pattern, a, b, c); + String actual = AnyStrings.format(pattern, a, b, c); Assert.assertEquals(expected, actual); } @Test public void testIsSubStringReproA() { - Assert.assertTrue(Strings.isSubString( + Assert.assertTrue(AnyStrings.isSubString( "qrqq40 078rh2n75kxu4prmgtlehv85iksxgehj5jk2prq66ls9bj2f6g5onx l18sgp7x414cik9tvpfycmhjgwhy9d3yhw4we", "b6r4e7g8f8sgu1cjfo16rg711cmft76wh83dsf46wwz3fse5j9chut37nhamqm4iw2f37ebl8tqr4fjmx8n6t943s4khdsf1qrqrqq40 078rh2n75kxu4prmgtlehv85iksxgehj5jk2prq66ls9bj2f6g5onx l18sgp7x414cik9tvpfycmhjgwhy9d3yhw4web6r4e7g8f8sgu1cjfo16rg711cmft76wh83dsf46wwz3fse5j9chut37nhamqm4iw2f37ebl8tqr4fjmx8n6t943s4khdsf1qr")); } @@ -125,32 +130,13 @@ public void testIsSubString() { String needle = Variables.register("needle", Random.getString()); String haystack = Variables.register("haystack", Random.getString()); Assert.assertEquals(haystack.contains(needle), - Strings.isSubString(needle, haystack)); - } - - @Test - public void testIsValidJsonObject() { - Assert.assertTrue(Strings - .isValidJson("{\"foo\": 1, \"bar\": \"2\", \"baz\":true}")); - } - - @Test - public void testIsValidJsonArray() { - Assert.assertTrue(Strings.isValidJson( - "[{\"foo\": 1, \"bar\": \"2\", \"baz\":true},{\"foo\": 1, \"bar\": \"2\", \"baz\":true},{\"foo\": 1, \"bar\": \"2\", \"baz\":true}]")); - } - - @Test - public void testIsValidJsonFalse() { - Assert.assertFalse(Strings.isValidJson("foo")); - Assert.assertFalse( - Strings.isValidJson("{\"foo\": 1, \"bar\": \"2\", \"baz\":}")); + AnyStrings.isSubString(needle, haystack)); } @Test public void testTryParseFloat() { float f = 0.3f; - Object obj = Strings.tryParseNumber("" + f + ""); + Object obj = AnyStrings.tryParseNumber("" + f + ""); Assert.assertTrue(obj instanceof Float); Assert.assertEquals(0.3f, obj); } @@ -158,7 +144,7 @@ public void testTryParseFloat() { @Test public void testTryParseDoubleAsFloat() { double f = 0.3; - Object obj = Strings.tryParseNumber("" + f + ""); + Object obj = AnyStrings.tryParseNumber("" + f + ""); Assert.assertTrue(obj instanceof Float); Assert.assertEquals(0.3f, obj); } @@ -167,60 +153,61 @@ public void testTryParseDoubleAsFloat() { public void testEscapeInnerDoubleQuote() { String string = "this has a \"double\" quote and 'single' quote"; String expected = "this has a \\\"double\\\" quote and 'single' quote"; - Assert.assertEquals(expected, Strings.escapeInner(string, '"')); + Assert.assertEquals(expected, AnyStrings.escapeInner(string, '"')); } @Test public void testEscapeInnerSingleQuote() { String string = "this has a 'single' quote and \"double\" quote"; String expected = "this has a \\'single\\' quote and \"double\" quote"; - Assert.assertEquals(expected, Strings.escapeInner(string, '\'')); + Assert.assertEquals(expected, AnyStrings.escapeInner(string, '\'')); } @Test public void testEscapeInnerNothing() { String string = "this should not be escaped"; String expected = string; - Assert.assertEquals(expected, Strings.escapeInner(string, '\"')); + Assert.assertEquals(expected, AnyStrings.escapeInner(string, '\"')); } @Test public void testEscapeInnerSingleAndDoubleQuotes() { String string = "this has a \"double\" and 'single' quote"; String expected = "this has a \\\"double\\\" and \\'single\\' quote"; - Assert.assertEquals(expected, Strings.escapeInner(string, '"', '\'')); + Assert.assertEquals(expected, + AnyStrings.escapeInner(string, '"', '\'')); } @Test public void testEscapeInnerNothingSkipHeadTail() { String string = "\"this should not be escaped\""; String expected = string; - Assert.assertEquals(expected, Strings.escapeInner(string, '\"')); + Assert.assertEquals(expected, AnyStrings.escapeInner(string, '\"')); } @Test public void testEscapeInnerDoubleQuoteSkipHeadTail() { String string = "\"this has a \"double\" and 'single' quote\""; String expected = "\"this has a \\\"double\\\" and 'single' quote\""; - Assert.assertEquals(expected, Strings.escapeInner(string, '\"')); + Assert.assertEquals(expected, AnyStrings.escapeInner(string, '\"')); } @Test public void testEscapeInnerLineBreak() { String string = "\"a\n\nb\""; String expected = "\"a\\n\\nb\""; - Assert.assertEquals(expected, Strings.escapeInner(string, '\n')); + Assert.assertEquals(expected, AnyStrings.escapeInner(string, '\n')); } @Test public void testDoNotParseStringAsNumberWithLeadingZero() { - Assert.assertNull(Strings.tryParseNumber("01")); + Assert.assertNull(AnyStrings.tryParseNumber("01")); } @Test public void testParseStringAsNumberIfDecimalWithLeadingZero() { Assert.assertTrue( - Strings.tryParseNumberStrict("0.0123") instanceof Number); + AnyStrings.tryParseNumberStrict("0.0123") instanceof Number); } @Test @@ -228,7 +215,7 @@ public void testEnsureStartsWithAlreadyTrue() { String prefix = Random.getString(); String string = prefix + Random.getString(); Assert.assertTrue( - Strings.ensureStartsWith(string, prefix).startsWith(prefix)); + AnyStrings.ensureStartsWith(string, prefix).startsWith(prefix)); } @Test @@ -239,63 +226,63 @@ public void testEnsureStartsWithNotAlreadyTrue() { string = Random.getString(); } Assert.assertTrue( - Strings.ensureStartsWith(string, prefix).startsWith(prefix)); + AnyStrings.ensureStartsWith(string, prefix).startsWith(prefix)); } @Test public void testEnsureWithinQuotesIfNeeded() { String string = "a b c"; Assert.assertEquals(string, - Strings.ensureWithinQuotesIfNeeded(string, ',')); + AnyStrings.ensureWithinQuotesIfNeeded(string, ',')); string = "a, b c"; - Assert.assertEquals(Strings.format("\"{}\"", string), - Strings.ensureWithinQuotesIfNeeded(string, ',')); + Assert.assertEquals(AnyStrings.format("\"{}\"", string), + AnyStrings.ensureWithinQuotesIfNeeded(string, ',')); string = "a, b \"c"; - Assert.assertEquals(Strings.format("'{}'", string), - Strings.ensureWithinQuotesIfNeeded(string, ',')); + Assert.assertEquals(AnyStrings.format("'{}'", string), + AnyStrings.ensureWithinQuotesIfNeeded(string, ',')); string = "a, b 'c"; - Assert.assertEquals(Strings.format("\"{}\"", string), - Strings.ensureWithinQuotesIfNeeded(string, ',')); + Assert.assertEquals(AnyStrings.format("\"{}\"", string), + AnyStrings.ensureWithinQuotesIfNeeded(string, ',')); string = "a, 'b' \"c\""; Assert.assertEquals("\"a, 'b' \\\"c\\\"\"", - Strings.ensureWithinQuotesIfNeeded(string, ',')); + AnyStrings.ensureWithinQuotesIfNeeded(string, ',')); } @Test public void testEscapeInnerWhenAlreadyEscaped() { String string = "this is a \\\"real\\\" \"real\" problem"; - string = Strings.ensureWithinQuotes(string); + string = AnyStrings.ensureWithinQuotes(string); String expected = "\"this is a \\\"real\\\" \\\"real\\\" problem\""; Assert.assertEquals(expected, - Strings.escapeInner(string, string.charAt(0))); + AnyStrings.escapeInner(string, string.charAt(0))); } @Test public void testTryParseNumberIpAddress() { - Assert.assertNull(Strings.tryParseNumber("23.229.8.250")); + Assert.assertNull(AnyStrings.tryParseNumber("23.229.8.250")); } @Test public void testTryParseNumberPeriod() { - Assert.assertNull(Strings.tryParseNumber(".")); + Assert.assertNull(AnyStrings.tryParseNumber(".")); } @Test public void testIsWithinQuotesQuotedEmptyString() { - Assert.assertFalse(Strings.isWithinQuotes("\"\"")); - Assert.assertFalse(Strings.isWithinQuotes("\'\'")); + Assert.assertFalse(AnyStrings.isWithinQuotes("\"\"")); + Assert.assertFalse(AnyStrings.isWithinQuotes("\'\'")); } @Test public void testEnsureWithinQuotesQuotedEmptyString() { String string = "\"\""; - Assert.assertEquals("\"\"\"\"", Strings.ensureWithinQuotes(string)); + Assert.assertEquals("\"\"\"\"", AnyStrings.ensureWithinQuotes(string)); } @Test public void testTryParseNumberDash() { String string = "-"; - Assert.assertNull(Strings.tryParseNumber(string)); + Assert.assertNull(AnyStrings.tryParseNumber(string)); } @Test @@ -304,34 +291,36 @@ public void testTryParseNumberDashes() { for (int i = 0; i < Random.getScaleCount(); ++i) { string += "-"; } - Assert.assertNull(Strings.tryParseNumber(string)); + Assert.assertNull(AnyStrings.tryParseNumber(string)); } @Test public void testReplaceUnicodeConfusables() { String expected = "\"a\""; Assert.assertEquals(expected, - Strings.replaceUnicodeConfusables(expected)); - Assert.assertEquals(expected, Strings.replaceUnicodeConfusables("˝a˝")); - Assert.assertEquals(expected, Strings.replaceUnicodeConfusables("″a‶")); + AnyStrings.replaceUnicodeConfusables(expected)); + Assert.assertEquals(expected, + AnyStrings.replaceUnicodeConfusables("˝a˝")); + Assert.assertEquals(expected, + AnyStrings.replaceUnicodeConfusables("″a‶")); } @Test public void testTryParseDoubleScientificNotation() { String value = "5.15501576938E-4"; - Assert.assertNotNull(Strings.tryParseNumber(value)); + Assert.assertNotNull(AnyStrings.tryParseNumber(value)); } @Test public void testTryParseFakeDoubleScientificNotationA() { String value = "5.1550e1576938E-4"; - Assert.assertNull(Strings.tryParseNumber(value)); + Assert.assertNull(AnyStrings.tryParseNumber(value)); } @Test public void testTryParseFakeDoubleScientificNotationV() { String value = "5.15501576938E"; - Assert.assertNull(Strings.tryParseNumber(value)); + Assert.assertNull(AnyStrings.tryParseNumber(value)); } } diff --git a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/ConvertTest.java b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/ConvertTest.java index 81d06ac557..a733947af7 100644 --- a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/ConvertTest.java +++ b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/ConvertTest.java @@ -29,6 +29,7 @@ import org.junit.Assert; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.Link; import com.cinchapi.concourse.Tag; import com.cinchapi.concourse.Timestamp; @@ -334,7 +335,7 @@ public void testConvertLong() { public void testConvertResolvableLink() { String key = Random.getString().replace(" ", ""); String value = Random.getObject().toString().replace(" ", ""); - String ccl = Strings.joinWithSpace(key, "=", value); + String ccl = AnyStrings.joinWithSpace(key, "=", value); ResolvableLink link = (ResolvableLink) Convert .stringToJava(Convert.stringToResolvableLinkInstruction(ccl)); Assert.assertEquals(ccl, link.getCcl()); @@ -344,7 +345,7 @@ public void testConvertResolvableLink() { public void testConvertResolvableLinkWithNumbers() { String key = Random.getNumber().toString(); String value = Random.getNumber().toString(); - String ccl = Strings.joinWithSpace(key, "=", value); + String ccl = AnyStrings.joinWithSpace(key, "=", value); ResolvableLink link = (ResolvableLink) Convert .stringToJava(Convert.stringToResolvableLinkInstruction(ccl)); Assert.assertEquals(ccl, link.getCcl()); @@ -388,8 +389,8 @@ public void testResolvableLinkKeyRegexWithNumbers() { public void testTransformValueToResolvableLink() { String key = Random.getString(); String value = Random.getObject().toString(); - String expected = Strings.joinSimple("@", - Strings.joinWithSpace(key, "=", value), "@"); + String expected = AnyStrings.joinSimple("@", + AnyStrings.joinWithSpace(key, "=", value), "@"); Assert.assertEquals(expected, Convert.stringToResolvableLinkSpecification(key, value)); } diff --git a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/QuoteAwareStringSplitterTest.java b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/QuoteAwareStringSplitterTest.java deleted file mode 100644 index 5815dc2ce8..0000000000 --- a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/QuoteAwareStringSplitterTest.java +++ /dev/null @@ -1,199 +0,0 @@ -/* - * Copyright (c) 2013-2019 Cinchapi Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.cinchapi.concourse.util; - -import java.util.List; - -import org.junit.Assert; -import org.junit.Test; - -import com.google.common.collect.Lists; - -/** - * Unit tests for the - * {@link com.cinchapi.concourse.util.QuoteAwareStringSplitter class}. - * - * @author Jeff Nelson - */ -public class QuoteAwareStringSplitterTest { - - /** - * Test logic for ensuring that the quote aware string splitter works. - * - * @param string - * @param delim - */ - private void doTestSplitWithQuotes(String string, char delim) { - QuoteAwareStringSplitter it = new QuoteAwareStringSplitter(string, - delim); - String[] toks = Strings.splitStringByDelimiterButRespectQuotes(string, - String.valueOf(delim)); - int i = 0; - while (it.hasNext()) { - String tok = toks[i]; - if(!tok.isEmpty()) { - String next = it.next(); - if(next.startsWith("'") && next.endsWith("'")) { - // Strings#splitStringByDelimiterButRespectQuotes replaces - // single quotes with double quotes, so we must do that here - // in order to do the comparison - next = "\"" + next.substring(1, next.length() - 1) + "\""; - } - Assert.assertEquals(tok, next); - } - ++i; - } - } - - @Test - public void testSplitWithSingleQuotes() { - doTestSplitWithQuotes( - "this string is going to be split by 'space but we are respecting' single quotes", - ' '); - } - - @Test - public void testSplitWithDoubleQuotes() { - doTestSplitWithQuotes( - "this string is going to be split by \"space but we are respecting\" double quotes", - ' '); - } - - @Test - public void testDontSplitOnApostrophe() { - doTestSplitWithQuotes( - "don't split the string on the apostrophe 'because it needs to work'", - ' '); - } - - @Test - public void testSplitOnNewlineLF() { - String string = "this\nis a 'quote across\nlines'"; - StringSplitter it = new QuoteAwareStringSplitter(string, - SplitOption.SPLIT_ON_NEWLINE); - Assert.assertEquals("this", it.next()); - Assert.assertEquals("is", it.next()); - Assert.assertEquals("a", it.next()); - Assert.assertEquals("'quote across\nlines'", it.next()); - } - - @Test - public void testSplitOnNewlineCR() { - String string = "this\nis a 'quote across\rlines'"; - StringSplitter it = new QuoteAwareStringSplitter(string, - SplitOption.SPLIT_ON_NEWLINE); - Assert.assertEquals("this", it.next()); - Assert.assertEquals("is", it.next()); - Assert.assertEquals("a", it.next()); - Assert.assertEquals("'quote across\rlines'", it.next()); - } - - @Test - public void testSplitOnNewlineCRLF() { - String string = "this\nis a 'quote across\r\nlines'"; - StringSplitter it = new QuoteAwareStringSplitter(string, - SplitOption.SPLIT_ON_NEWLINE); - Assert.assertEquals("this", it.next()); - Assert.assertEquals("is", it.next()); - Assert.assertEquals("a", it.next()); - Assert.assertEquals("'quote across\r\nlines'", it.next()); - } - - @Test - public void testTokenizeParenthesis() { - String string = "foo(bar) \"but don't (split this)\" but split ( this)"; - StringSplitter it = new QuoteAwareStringSplitter(string, - SplitOption.TOKENIZE_PARENTHESIS); - while (it.hasNext()) { - Assert.assertEquals("foo", it.next()); - Assert.assertEquals("(", it.next()); - Assert.assertEquals("bar", it.next()); - Assert.assertEquals(")", it.next()); - Assert.assertEquals("\"but don't (split this)\"", it.next()); - Assert.assertEquals("but", it.next()); - Assert.assertEquals("split", it.next()); - Assert.assertEquals("(", it.next()); - Assert.assertEquals("this", it.next()); - Assert.assertEquals(")", it.next()); - } - } - - @Test - public void testDropQuotes() { - String string = "a,b,\"c,d,efg,h\""; - QuoteAwareStringSplitter it = new QuoteAwareStringSplitter(string, ',', - SplitOption.DROP_QUOTES); - while (it.hasNext()) { - Assert.assertFalse(Strings.isWithinQuotes(it.next())); - } - } - - @Test - public void testHandleEscapedQuotes() { - String string = "103403,theme_mods_simplemag,\"a:63:{i:0;b:0;s:7:\\\"backups\\\";N;s:9:\\\"smof_init\\\";s:31:\\\"Mon, 26 May 2014 23:29:41 +0000\\\";s:9:\\\"site_logo\\\";s:58:\\\"[site_url]/wp-content/uploads/2014/04/Blavitylogoblack.png\\\";s:12:\\\"site_tagline\\\";s:1:\\\"0\\\";s:12:\\\"site_favicon\\\";s:49:\\\"[site_url]/wp-content/uploads/2014/05/favicon.ico\\\";s:19:\\\"site_retina_favicon\\\";s:0:\\\"\\\";s:14:\\\"site_top_strip\\\";i:1;s:22:\\\"site_sidebar_behaviour\\\";s:1:\\\"1\\\";s:24:\\\"site_wide_excerpt_length\\\";s:2:\\\"24\\\";s:17:\\\"site_wide_excerpt\\\";i:1;s:18:\\\"site_page_comments\\\";i:0;s:16:\\\"site_author_name\\\";i:0;s:14:\\\"copyright_text\\\";s:22:\\\"Copyright Blavity 2014\\\";s:15:\\\"main_site_color\\\";s:7:\\\"#ffffff\\\";s:20:\\\"site_top_strip_color\\\";s:16:\\\"color-site-white\\\";s:15:\\\"main_menu_links\\\";s:4:\\\"14px\\\";s:11:\\\"slider-tint\\\";s:16:\\\"slider-tint-dark\\\";s:20:\\\"slider_tint_strength\\\";s:3:\\\"0.1\\\";s:26:\\\"slider_tint_strength_hover\\\";s:3:\\\"0.7\\\";s:17:\\\"site_footer_color\\\";s:15:\\\"color-site-gray\\\";s:11:\\\"font_titles\\\";s:5:\\\"Bayon\\\";s:9:\\\"font_text\\\";s:4:\\\"Lato\\\";s:21:\\\"single_media_position\\\";s:9:\\\"fullwidth\\\";s:21:\\\"single_featured_image\\\";i:1;s:18:\\\"single_author_name\\\";i:0;s:17:\\\"single_wp_gallery\\\";i:1;s:13:\\\"single_social\\\";i:1;s:13:\\\"single_author\\\";i:1;s:17:\\\"single_nav_arrows\\\";i:1;s:10:\\\"post_score\\\";s:38:\\\"

Post Score

\\\";s:19:\\\"single_rating_title\\\";s:10:\\\"Our Rating\\\";s:22:\\\"single_breakdown_title\\\";s:13:\\\"The Breakdown\\\";s:18:\\\"related_posts_info\\\";s:41:\\\"

Related Posts

\\\";s:14:\\\"single_related\\\";s:1:\\\"0\\\";s:20:\\\"single_related_title\\\";s:17:\\\"You may also like\\\";s:28:\\\"single_related_posts_to_show\\\";s:1:\\\"2\\\";s:15:\\\"slide_dock_info\\\";s:51:\\\"

Random Posts Slide Dock

\\\";s:17:\\\"single_slide_dock\\\";i:1;s:23:\\\"single_slide_dock_title\\\";s:12:\\\"More Stories\\\";s:23:\\\"single_slide_dock_style\\\";i:0;s:19:\\\"top_social_profiles\\\";s:1:\\\"1\\\";s:7:\\\"sp_feed\\\";s:0:\\\"\\\";s:11:\\\"sp_facebook\\\";s:24:\\\"www.facebook.com/Blavity\\\";s:10:\\\"sp_twitter\\\";s:23:\\\"www.Twitter.com/Blavity\\\";s:9:\\\"sp_google\\\";s:36:\\\"https://plus.google.com/+BlavityPage\\\";s:11:\\\"sp_linkedin\\\";s:0:\\\"\\\";s:12:\\\"sp_instagram\\\";s:28:\\\"http://instagram.com/blavity\\\";s:9:\\\"sp_flickr\\\";s:0:\\\"\\\";s:8:\\\"sp_vimeo\\\";s:0:\\\"\\\";s:10:\\\"sp_youtube\\\";s:0:\\\"\\\";s:10:\\\"sp_behance\\\";s:0:\\\"\\\";s:10:\\\"sp_dribble\\\";s:0:\\\"\\\";s:12:\\\"sp_pinterest\\\";s:0:\\\"\\\";s:13:\\\"sp_soundcloud\\\";s:0:\\\"\\\";s:9:\\\"sp_lastfm\\\";s:0:\\\"\\\";s:10:\\\"custom_css\\\";s:35:\\\".single .message { display: none; }\\\";s:16:\\\"custom_js_header\\\";s:0:\\\"\\\";s:16:\\\"custom_js_footer\\\";s:0:\\\"\\\";s:11:\\\"error_title\\\";s:56:\\\"Omph. Our bad. We're rolling our eyes too! Try again. :)\\\";s:11:\\\"error_image\\\";s:60:\\\"[site_url]/wp-content/uploads/2014/05/hangout_snapshot_2.jpg\\\";s:18:\\\"nav_menu_locations\\\";a:2:{s:9:\\\"main_menu\\\";i:2;s:14:\\\"secondary_menu\\\";i:26;}s:16:\\\"sidebars_widgets\\\";a:2:{s:4:\\\"time\\\";i:1407380058;s:4:\\\"data\\\";a:6:{s:19:\\\"wp_inactive_widgets\\\";a:1:{i:0;s:6:\\\"text-2\\\";}s:9:\\\"sidebar-1\\\";a:4:{i:0;s:14:\\\"mc4wp_widget-4\\\";i:1;s:17:\\\"ti_image_banner-2\\\";i:2;s:18:\\\"facebook-likebox-2\\\";i:3;s:14:\\\"recent-posts-2\\\";}s:9:\\\"sidebar-2\\\";a:3:{i:0;s:16:\\\"ti_video_embed-2\\\";i:1;s:17:\\\"ti_latest_posts-2\\\";i:2;s:10:\\\"nav_menu-3\\\";}s:9:\\\"sidebar-3\\\";a:1:{i:0;s:10:\\\"nav_menu-2\\\";}s:9:\\\"sidebar-4\\\";a:1:{i:0;s:14:\\\"mc4wp_widget-5\\\";}s:9:\\\"sidebar-5\\\";a:0:{}}}}\",yes,wp_options"; - QuoteAwareStringSplitter it = new QuoteAwareStringSplitter(string, ','); - int count = 0; - while (it.hasNext()) { - it.next(); - ++count; - } - Assert.assertEquals(5, count); - } - - @Test - public void testHandleLeadingApostrophe() { - String string = "12 great theme songs every '90s black kid will remember,,inherit,closed,closed,,14321-revision-v1,,,2015-08-17 16:01:05,2015-08-17 20:01:05,,14321,http://staging.blavity.com/14321-revision-v1/,0,revision,,0,wp_posts\n17114,616166,2015-10-07 22:1Exception in thread"; - QuoteAwareStringSplitter it = new QuoteAwareStringSplitter(string, ','); - String[] toks = string.split(","); - int count = 0; - while (it.hasNext()) { - Assert.assertEquals(toks[count], it.next()); - ++count; - } - } - - @Test - public void testHandleLeadingApostropeAndQuotes() { - String string = "'90s kids are awesome,a,b,\"here,is,a,quote\",c,d,\"and,another,quote\""; - QuoteAwareStringSplitter it = new QuoteAwareStringSplitter(string, ','); - int count = 0; - while (it.hasNext()) { - it.next(); - ++count; - } - Assert.assertEquals(7, count); - } - - @Test - public void testQuoteAwareTrim() { - String string = "a, b, \"c, d, e\", f ,g"; - StringSplitter it = new QuoteAwareStringSplitter(string, ',', - SplitOption.TRIM_WHITESPACE); - List expected = Lists.newArrayList("a", "b", "\"c, d, e\"", "f", - "g"); - int index = 0; - while (it.hasNext()) { - String next = it.next(); - if(!next.contains("\"")) { - Assert.assertFalse(next.contains(" ")); - } - Assert.assertEquals(expected.get(index), next); - ++index; - } - - } - -} diff --git a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterPerformanceTest.java b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterPerformanceTest.java index 5c8e6debb5..93570434c4 100644 --- a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterPerformanceTest.java +++ b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterPerformanceTest.java @@ -18,6 +18,9 @@ import org.junit.Ignore; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; +import com.cinchapi.common.base.QuoteAwareStringSplitter; +import com.cinchapi.common.base.StringSplitter; import com.cinchapi.concourse.test.ConcourseBenchmarkTest; /** @@ -29,6 +32,10 @@ @SuppressWarnings("unused") public class StringSplitterPerformanceTest extends ConcourseBenchmarkTest { + // NOTE: This is a unit test for StringSplliter, which is defined in + // accent4j. This test depends on ConcourseBenchmarkTest, so it is defined + // in this project instead of the same one as the class being tested. + @Test @Ignore public void testSimpleSplit() { @@ -74,7 +81,7 @@ public void testQuoteAwareSplit() { int rounds = 5000; startBenchmark(builtInBenchmark); for (int i = 0; i < rounds; ++i) { - String[] toks = Strings + String[] toks = AnyStrings .splitStringByDelimiterButRespectQuotes(string, ","); for (String tok : toks) { continue; diff --git a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterTest.java b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterTest.java index 8c17492de4..7c6117dac2 100644 --- a/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterTest.java +++ b/concourse-driver-java/src/test/java/com/cinchapi/concourse/util/StringSplitterTest.java @@ -22,18 +22,25 @@ import org.junit.Assert; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; +import com.cinchapi.common.base.SplitOption; +import com.cinchapi.common.base.StringSplitter; import com.cinchapi.concourse.test.ConcourseBaseTest; import com.cinchapi.concourse.test.Variables; import com.google.common.collect.Lists; import com.google.common.collect.Sets; /** - * Unit tests for the {@link com.cinchapi.concourse.util.StringSplitter} class. + * Unit tests for the {@link StringSplitter} class. * * @author Jeff Nelson */ public class StringSplitterTest extends ConcourseBaseTest { + // NOTE: This is a unit test for StringSplliter, which is defined in + // accent4j. This test depends on ConcourseBaseTest, so it is defined in + // this project instead of the same one as the class being tested. + @Test public void testStringSplitter() { String string = Random.getString(); @@ -97,7 +104,7 @@ public void testSplitOnNewlineEnabled() { @Test public void testSplitOnNewlineLF() { Set expected = Sets.newHashSet("line1", "line2", "line3"); - String string = Strings.join('\n', expected.toArray()); + String string = AnyStrings.join('\n', expected.toArray()); StringSplitter it = new StringSplitter(string, SplitOption.SPLIT_ON_NEWLINE); while (it.hasNext()) { @@ -108,7 +115,7 @@ public void testSplitOnNewlineLF() { @Test public void testSplitOnNewlineCR() { Set expected = Sets.newHashSet("line1", "line2", "line3"); - String string = Strings.join('\r', expected.toArray()); + String string = AnyStrings.join('\r', expected.toArray()); StringSplitter it = new StringSplitter(string, SplitOption.SPLIT_ON_NEWLINE); while (it.hasNext()) { @@ -119,7 +126,7 @@ public void testSplitOnNewlineCR() { @Test public void testSplitOnNewlineCRLF() { Set expected = Sets.newHashSet("line1", "line2", "line3"); - String string = Strings.join("\r\n", expected.toArray()); + String string = AnyStrings.join("\r\n", expected.toArray()); StringSplitter it = new StringSplitter(string, SplitOption.SPLIT_ON_NEWLINE); while (it.hasNext()) { diff --git a/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java b/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java index 5767df0b06..4ea893bb79 100644 --- a/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java +++ b/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java @@ -55,6 +55,7 @@ import ch.qos.logback.classic.Level; import com.cinchapi.ccl.grammar.Symbol; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.ArrayBuilder; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.common.process.Processes; @@ -73,7 +74,6 @@ import com.cinchapi.concourse.time.Time; import com.cinchapi.concourse.util.ConcourseServerDownloader; import com.cinchapi.concourse.util.FileOps; -import com.cinchapi.concourse.util.Strings; import com.google.common.base.Stopwatch; import com.google.common.collect.Iterables; import com.google.common.collect.Lists; @@ -638,7 +638,7 @@ public boolean installPlugin(Path bundle) { return true; } } - throw new RuntimeException(Strings + throw new RuntimeException(AnyStrings .format("Unable to install plugin '{}': {}", bundle, out)); } diff --git a/concourse-import/src/main/java/com/cinchapi/concourse/importer/LineBasedImporter.java b/concourse-import/src/main/java/com/cinchapi/concourse/importer/LineBasedImporter.java index 5195cd3498..0f58f67d9f 100644 --- a/concourse-import/src/main/java/com/cinchapi/concourse/importer/LineBasedImporter.java +++ b/concourse-import/src/main/java/com/cinchapi/concourse/importer/LineBasedImporter.java @@ -23,13 +23,13 @@ import org.apache.commons.lang.StringUtils; import org.slf4j.Logger; +import com.cinchapi.common.base.AnyStrings; +import com.cinchapi.common.base.QuoteAwareStringSplitter; import com.cinchapi.concourse.Concourse; import com.cinchapi.concourse.Constants; import com.cinchapi.concourse.thrift.Operator; import com.cinchapi.concourse.util.Convert; import com.cinchapi.concourse.util.FileOps; -import com.cinchapi.concourse.util.QuoteAwareStringSplitter; -import com.cinchapi.concourse.util.Strings; import com.cinchapi.concourse.util.TLists; import com.google.common.collect.Lists; import com.google.gson.JsonArray; @@ -201,10 +201,10 @@ protected String[] header() { protected JsonElement transformValue(String key, String value) { JsonPrimitive element; Object parsed; - if((parsed = Strings.tryParseNumberStrict(value)) != null) { + if((parsed = AnyStrings.tryParseNumberStrict(value)) != null) { element = new JsonPrimitive((Number) parsed); } - else if((parsed = Strings.tryParseBoolean(value)) != null) { + else if((parsed = AnyStrings.tryParseBoolean(value)) != null) { element = new JsonPrimitive((Boolean) parsed); } else { @@ -245,7 +245,7 @@ private final String[] parseKeys(String line) { keys = TLists.toArrayCasted(keysList, String.class); } else { - keys = Strings.splitStringByDelimiterButRespectQuotes(line, + keys = AnyStrings.splitStringByDelimiterButRespectQuotes(line, delimiter()); for (int i = 0; i < keys.length; ++i) { keys[i] = keys[i].trim(); @@ -278,7 +278,7 @@ private final JsonObject parseLine(String line, String... keys) { toks = TLists.toArrayCasted(toksList, String.class); } else { - toks = Strings.splitStringByDelimiterButRespectQuotes(line, + toks = AnyStrings.splitStringByDelimiterButRespectQuotes(line, delimiter()); } for (int i = 0; i < Math.min(keys.length, toks.length); ++i) { diff --git a/concourse-import/src/main/java/com/cinchapi/concourse/importer/cli/ImportCli.java b/concourse-import/src/main/java/com/cinchapi/concourse/importer/cli/ImportCli.java index d6a8d6b80b..3ee7f6a598 100644 --- a/concourse-import/src/main/java/com/cinchapi/concourse/importer/cli/ImportCli.java +++ b/concourse-import/src/main/java/com/cinchapi/concourse/importer/cli/ImportCli.java @@ -42,6 +42,7 @@ import org.reflections.Reflections; import com.beust.jcommander.Parameter; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.common.groovy.GroovyFiles; import com.cinchapi.common.io.Files; @@ -56,7 +57,6 @@ import com.cinchapi.concourse.importer.LegacyCsvImporter; import com.cinchapi.concourse.importer.debug.ImportDryRunConcourse; import com.cinchapi.concourse.util.FileOps; -import com.cinchapi.concourse.util.Strings; import com.google.common.base.CaseFormat; import com.google.common.base.Stopwatch; import com.google.common.base.Throwables; @@ -150,7 +150,7 @@ public void run() { if(options.verbose) { System.out.println(records); } - System.out.println(Strings.format( + System.out.println(AnyStrings.format( "Imported data into {} record{}", records.size(), records.size() > 1 ? "s" : "")); if(dryRun) { @@ -287,7 +287,7 @@ public void run() { if(options.verbose) { System.out.println(records); } - System.out.println(Strings.format( + System.out.println(AnyStrings.format( "Imported data into {} record{} in {} seconds", records.size(), records.size() > 1 ? "s" : "", seconds)); if(dryRun) { @@ -343,7 +343,7 @@ private static Constructor getConstructor(String type) { clz = getCustomImporterClass(type); } catch (ClassNotFoundException e) { - throw new RuntimeException(Strings + throw new RuntimeException(AnyStrings .format("{} is not a valid importer type.", type)); } } @@ -440,7 +440,7 @@ else if(path.toString().endsWith(".jar")) { } } else { - throw new UnsupportedOperationException(Strings.format( + throw new UnsupportedOperationException(AnyStrings.format( "{} is an unsupported file type for custom importers", path)); } diff --git a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/InsertTest.java b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/InsertTest.java index d2e7e8f524..720a23e39a 100644 --- a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/InsertTest.java +++ b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/InsertTest.java @@ -22,9 +22,9 @@ import org.junit.Assert; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.test.ConcourseIntegrationTest; import com.cinchapi.concourse.thrift.Operator; -import com.cinchapi.concourse.util.Strings; import com.cinchapi.concourse.util.TestData; import com.google.common.collect.HashMultimap; import com.google.common.collect.Iterables; @@ -131,7 +131,7 @@ long record = Iterables.getOnlyElement(client.find("foo = 20")); Assert.assertEquals( Sets.newHashSet( Iterables.getOnlyElement(client.find("_id = 1"))), - client.find(Strings.format("bar lnks2 {}", record))); + client.find(AnyStrings.format("bar lnks2 {}", record))); } @Test diff --git a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/importer/ResolveKeyTest.java b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/importer/ResolveKeyTest.java index ef26c8f298..14579e9297 100644 --- a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/importer/ResolveKeyTest.java +++ b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/importer/ResolveKeyTest.java @@ -23,9 +23,9 @@ import org.junit.Ignore; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.util.FileOps; import com.cinchapi.concourse.util.Resources; -import com.cinchapi.concourse.util.Strings; import com.google.common.collect.Iterables; /** @@ -57,7 +57,7 @@ public void testResolveKey() { int i = 0; for (String line : lines) { if(i > 0) { - String[] toks = Strings + String[] toks = AnyStrings .splitStringByDelimiterButRespectQuotes(line, ","); String ipedsId = toks[0]; Long record = Iterables.get(records, i); diff --git a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/shell/ConcourseShellTest.java b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/shell/ConcourseShellTest.java index 50af3095c3..eecf928f8c 100644 --- a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/shell/ConcourseShellTest.java +++ b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/shell/ConcourseShellTest.java @@ -21,10 +21,10 @@ import org.junit.Assert; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.concourse.test.ConcourseIntegrationTest; import com.cinchapi.concourse.util.Resources; -import com.cinchapi.concourse.util.Strings; import com.cinchapi.concourse.util.TestData; /** @@ -90,7 +90,7 @@ public void testSecurityChangeCausesCrash() throws Throwable { public void testImportedClasssesAreAccessible() throws Throwable { for (Class clazz : ConcourseShell.IMPORTED_CLASSES) { String variable = clazz.getSimpleName(); - String expected = Strings.format("Returned 'class {}'", + String expected = AnyStrings.format("Returned 'class {}'", clazz.getName()); String actual = cash.evaluate(variable); actual = actual.split(" in ")[0]; diff --git a/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/MessageQueue.java b/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/MessageQueue.java index 4053ac2490..00db0f171e 100644 --- a/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/MessageQueue.java +++ b/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/MessageQueue.java @@ -33,10 +33,10 @@ import java.util.concurrent.BlockingQueue; import java.util.concurrent.LinkedBlockingQueue; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.concourse.server.plugin.concurrent.FileLocks; import com.cinchapi.concourse.util.FileOps; -import com.cinchapi.concourse.util.Strings; import com.google.common.collect.Maps; /** @@ -172,7 +172,7 @@ public MessageQueue(String file) { }); acceptor.setDaemon(true); acceptor.setUncaughtExceptionHandler((t, e) -> { - RuntimeException ex = new RuntimeException(Strings.format( + RuntimeException ex = new RuntimeException(AnyStrings.format( "Uncaught exception in Thread {}: {}", t, e), e); ex.printStackTrace(); }); @@ -285,7 +285,7 @@ private void register() { @Override public String toString() { - return Strings.format("MessageQueue[pending = {}]", messages); + return AnyStrings.format("MessageQueue[pending = {}]", messages); } } diff --git a/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/SharedMemory.java b/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/SharedMemory.java index 893c48770f..e334a71f62 100644 --- a/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/SharedMemory.java +++ b/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/io/SharedMemory.java @@ -32,11 +32,11 @@ import javax.annotation.concurrent.ThreadSafe; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.concourse.server.plugin.concurrent.FileLocks; import com.cinchapi.concourse.util.ByteBuffers; import com.cinchapi.concourse.util.FileOps; -import com.cinchapi.concourse.util.Strings; import com.google.common.annotations.VisibleForTesting; import com.google.common.util.concurrent.ThreadFactoryBuilder; @@ -441,7 +441,7 @@ public ByteBuffer read() { @Override public String toString() { - return Strings.format( + return AnyStrings.format( "SharedMemory[path={}, nextRead={}, nextWrite={}]", location, nextRead.get(), nextWrite.get()); } diff --git a/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/util/Versions.java b/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/util/Versions.java index 0c26c544c0..97b0fdce1a 100644 --- a/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/util/Versions.java +++ b/concourse-plugin-core/src/main/java/com/cinchapi/concourse/server/plugin/util/Versions.java @@ -17,7 +17,7 @@ import java.util.Arrays; -import com.cinchapi.concourse.util.Strings; +import com.cinchapi.common.base.AnyStrings; import com.github.zafarkhaja.semver.Version; /** @@ -47,7 +47,7 @@ public static Version parseSemanticVersion(String version) { .append(toks[2]); toks = toks[3].split("-"); if(toks.length > 1) { - sb.append('-').append(Strings.join("-", + sb.append('-').append(AnyStrings.join("-", (Object[]) Arrays.copyOfRange(toks, 1, toks.length))); } sb.append('+').append(toks[0]); diff --git a/concourse-plugin-core/src/test/java/com/cinchapi/concourse/server/plugin/util/VersionsTest.java b/concourse-plugin-core/src/test/java/com/cinchapi/concourse/server/plugin/util/VersionsTest.java index a083bd6656..a1fc3e8e7b 100644 --- a/concourse-plugin-core/src/test/java/com/cinchapi/concourse/server/plugin/util/VersionsTest.java +++ b/concourse-plugin-core/src/test/java/com/cinchapi/concourse/server/plugin/util/VersionsTest.java @@ -18,8 +18,8 @@ import org.junit.Assert; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.util.Random; -import com.cinchapi.concourse.util.Strings; import com.github.zafarkhaja.semver.Version; /** @@ -36,8 +36,8 @@ public void testParseCinchapiSemanticVersion() { int patch = Random.getScaleCount(); int build = Random.getScaleCount(); String snapshot = Random.getBoolean() ? "-SNAPSHOT" : ""; - String cinchapiVersion = Strings.format("{}.{}.{}.{}{}", major, minor, - patch, build, snapshot); + String cinchapiVersion = AnyStrings.format("{}.{}.{}.{}{}", major, + minor, patch, build, snapshot); Version version = Versions.parseSemanticVersion(cinchapiVersion); Assert.assertEquals(major, version.getMajorVersion()); Assert.assertEquals(minor, version.getMinorVersion()); @@ -52,8 +52,8 @@ public void testParseCinchapiFeatureBranchSemanticVersion() { int patch = 0; int build = 26; String snapshot = "-CON-512"; - String cinchapiVersion = Strings.format("{}.{}.{}.{}{}", major, minor, - patch, build, snapshot); + String cinchapiVersion = AnyStrings.format("{}.{}.{}.{}{}", major, + minor, patch, build, snapshot); Version version = Versions.parseSemanticVersion(cinchapiVersion); Assert.assertEquals(major, version.getMajorVersion()); Assert.assertEquals(minor, version.getMinorVersion()); diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/ConcourseServer.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/ConcourseServer.java index 76c7d061bc..66cbb458bc 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/ConcourseServer.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/ConcourseServer.java @@ -49,6 +49,7 @@ import com.cinchapi.ccl.Parser; import com.cinchapi.ccl.syntax.AbstractSyntaxTree; import com.cinchapi.ccl.util.NaturalLanguage; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.reflect.Reflection; import com.cinchapi.concourse.Constants; import com.cinchapi.concourse.Link; @@ -1789,10 +1790,8 @@ long record = Time.now(); return Iterables.getOnlyElement(records); } else { - throw new DuplicateEntryException( - com.cinchapi.concourse.util.Strings.joinWithSpace("Found", - records.size(), "records that match", key, "=", - value)); + throw new DuplicateEntryException(AnyStrings.joinWithSpace("Found", + records.size(), "records that match", key, "=", value)); } } @@ -1825,9 +1824,8 @@ public long findOrInsertCclJson(String ccl, String json, AccessToken creds, return Iterables.getOnlyElement(records); } else { - throw new DuplicateEntryException( - com.cinchapi.concourse.util.Strings.joinWithSpace("Found", - records.size(), "records that match", ccl)); + throw new DuplicateEntryException(AnyStrings.joinWithSpace("Found", + records.size(), "records that match", ccl)); } } @@ -1852,9 +1850,8 @@ public long findOrInsertCriteriaJson(TCriteria criteria, String json, return Iterables.getOnlyElement(records); } else { - throw new DuplicateEntryException( - com.cinchapi.concourse.util.Strings.joinWithSpace("Found", - records.size(), "records that match", parser)); + throw new DuplicateEntryException(AnyStrings.joinWithSpace("Found", + records.size(), "records that match", parser)); } } diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/cli/plugin/InstallPluginCli.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/cli/plugin/InstallPluginCli.java index 2cd55d2401..dd4afc75a4 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/cli/plugin/InstallPluginCli.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/cli/plugin/InstallPluginCli.java @@ -23,6 +23,7 @@ import org.apache.thrift.TException; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.cli.util.CommandLineInterfaces; import com.cinchapi.concourse.server.cli.core.CommandLineInterfaceInformation; import com.cinchapi.concourse.server.concurrent.Threads; @@ -30,7 +31,6 @@ import com.cinchapi.concourse.server.management.ConcourseManagementService.Client; import com.cinchapi.concourse.thrift.ManagementException; import com.cinchapi.concourse.util.FileOps; -import com.cinchapi.concourse.util.Strings; /** * A cli for installing plugins. @@ -56,7 +56,7 @@ protected void doTask(Client client) { String path = FileSystem.expandPath(plugin, getLaunchDirectory()); Path path0 = Paths.get(path); if(Files.isDirectory(path0)) { - System.out.println(Strings.format( + System.out.println(AnyStrings.format( "Attempting to install plugin bundles from '{}'", path0)); AtomicInteger installed = new AtomicInteger(0); FileOps.newDirectoryStream(path0).forEach((file) -> { @@ -72,13 +72,13 @@ protected void doTask(Client client) { } } else { - System.err.println(Strings.format( + System.err.println(AnyStrings.format( "[WARN] Skipping '{}' because it is a directory", file)); } }); - System.out - .println(Strings.format("Installed a total of {} plugin{}", + System.out.println( + AnyStrings.format("Installed a total of {} plugin{}", installed.get(), installed.get() == 1 ? "" : "s")); } else if(Files.exists(path0)) { @@ -90,12 +90,11 @@ else if(Files.exists(path0)) { } } else { - throw new UnsupportedOperationException( - com.cinchapi.concourse.util.Strings - .format("Cannot download plugin bundle '{}'. Please " - + "manually download the plugin and " - + "provide its local path to the " - + "installer", plugin)); + throw new UnsupportedOperationException(AnyStrings.format( + "Cannot download plugin bundle '{}'. Please " + + "manually download the plugin and " + + "provide its local path to the " + "installer", + plugin)); } } diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/http/EndpointContainer.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/http/EndpointContainer.java index 06051bc2e5..d282ed365a 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/http/EndpointContainer.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/http/EndpointContainer.java @@ -20,10 +20,10 @@ import java.util.List; import com.cinchapi.common.base.AdHocIterator; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.reflect.Reflection; import com.cinchapi.concourse.server.ConcourseServer; import com.cinchapi.concourse.util.Random; -import com.cinchapi.concourse.util.Strings; import com.google.common.annotations.VisibleForTesting; import com.google.common.base.CaseFormat; @@ -133,11 +133,11 @@ private static String getCanonicalNamespace(RoutingKey id) { namespace = id.cls; } else { - namespace = Strings.join('/', id.module, id.cls); + namespace = AnyStrings.join('/', id.module, id.cls); } } else { - namespace = Strings.join('/', id.group, id.module, id.cls); + namespace = AnyStrings.join('/', id.group, id.module, id.cls); } namespace = namespace.replace("Router", ""); namespace = namespace.replace("Index", ""); @@ -146,8 +146,8 @@ private static String getCanonicalNamespace(RoutingKey id) { namespace = CaseFormat.UPPER_CAMEL.to(CaseFormat.LOWER_HYPHEN, namespace); namespace = namespace.replaceAll("/-", "/"); - namespace = Strings.ensureStartsWith(namespace, "/"); - namespace = Strings.ensureEndsWith(namespace, "/"); + namespace = AnyStrings.ensureStartsWith(namespace, "/"); + namespace = AnyStrings.ensureEndsWith(namespace, "/"); return namespace; } @@ -237,12 +237,12 @@ protected Endpoint findNext() { || name.startsWith("upsert") || name.startsWith( "options"))) { - List args = Strings + List args = AnyStrings .splitCamelCase(field.getName()); action = args.remove(0); path = buildSparkPath(args); } - path = Strings.joinSimple(namespace, path); + path = AnyStrings.joinSimple(namespace, path); Reflection.set("action", action, callable); Reflection.set("path", path, callable); return callable; diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/http/RoutingKey.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/http/RoutingKey.java index 958716c034..3b7b3f367b 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/http/RoutingKey.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/http/RoutingKey.java @@ -17,8 +17,8 @@ import javax.annotation.concurrent.Immutable; -import com.cinchapi.concourse.util.StringSplitter; -import com.cinchapi.concourse.util.Strings; +import com.cinchapi.common.base.AnyStrings; +import com.cinchapi.common.base.StringSplitter; /** * A {@link RoutingKey} contains information to uniquely identify a @@ -128,7 +128,7 @@ private RoutingKey(String group, String module, String cls) { @Override public String toString() { - return Strings.join(':', group, module, cls); + return AnyStrings.join(':', group, module, cls); } } diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/http/webserver/ConcourseHttpHandler.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/http/webserver/ConcourseHttpHandler.java index 882ed75715..174470302f 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/http/webserver/ConcourseHttpHandler.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/http/webserver/ConcourseHttpHandler.java @@ -32,12 +32,12 @@ import spark.webserver.NotConsumedException; import com.cinchapi.common.base.AnyObjects; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.common.reflect.Reflection; import com.cinchapi.concourse.server.GlobalState; import com.cinchapi.concourse.server.http.HttpAuthToken; import com.cinchapi.concourse.server.http.HttpRequests; -import com.cinchapi.concourse.util.Strings; /** * Simple Jetty Handler @@ -225,7 +225,7 @@ public void doHandle(String target, Request baseRequest, } else { String requestOrigin = request.getHeader("Origin"); - if(Strings.isSubString(requestOrigin, + if(AnyStrings.isSubString(requestOrigin, GlobalState.HTTP_CORS_DEFAULT_ALLOW_ORIGIN)) { response.addHeader(HEADER_ACCESS_CONTROL_ALLOW_ORIGIN, requestOrigin); diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/ops/Operations.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/ops/Operations.java index f52fbb11af..af3b02af0f 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/ops/Operations.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/ops/Operations.java @@ -23,6 +23,7 @@ import com.cinchapi.ccl.Parser; import com.cinchapi.ccl.syntax.AbstractSyntaxTree; +import com.cinchapi.common.base.StringSplitter; import com.cinchapi.concourse.Constants; import com.cinchapi.concourse.Link; import com.cinchapi.concourse.server.ConcourseServer.DeferredWrite; @@ -44,7 +45,6 @@ import com.cinchapi.concourse.util.LinkNavigation; import com.cinchapi.concourse.util.Numbers; import com.cinchapi.concourse.util.Parsers; -import com.cinchapi.concourse.util.StringSplitter; import com.google.common.collect.Lists; import com.google.common.collect.Maps; import com.google.common.collect.Multimap; diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/plugin/PluginManager.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/plugin/PluginManager.java index a3a6f4797c..f8d1afe0c7 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/plugin/PluginManager.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/plugin/PluginManager.java @@ -48,6 +48,7 @@ import org.reflections.util.ClasspathHelper; import org.reflections.util.ConfigurationBuilder; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.common.reflect.Reflection; import com.cinchapi.concourse.server.ConcourseServer; @@ -68,7 +69,6 @@ import com.cinchapi.concourse.util.MorePaths; import com.cinchapi.concourse.util.Queues; import com.cinchapi.concourse.util.Resources; -import com.cinchapi.concourse.util.Strings; import com.cinchapi.concourse.util.ZipFiles; import com.github.zafarkhaja.semver.Version; import com.google.common.base.Throwables; @@ -461,7 +461,7 @@ public ComplexTObject invoke(String plugin, String method, + "configured to use the alias '{}' so it is not permitted. " + "Please invoke the plugin using its full qualified name" : "No plugin with id or alias {} exists"; - throw new PluginException(Strings.format(message, clazz)); + throw new PluginException(AnyStrings.format(message, clazz)); } RemoteMethodRequest request = new RemoteMethodRequest(method, creds, transaction, environment, args); @@ -476,7 +476,7 @@ public ComplexTObject invoke(String plugin, String method, } else { Logger.error("Plugin Exception:", response.error); - throw new PluginException(Strings.format( + throw new PluginException(AnyStrings.format( "An error occurred when invoking '{}' in '{}': ", method, clazz, response.error)); } diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Engine.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Engine.java index d1fa4ba9a6..c9f86724e1 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Engine.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Engine.java @@ -37,6 +37,7 @@ import javax.annotation.concurrent.ThreadSafe; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.annotate.Authorized; import com.cinchapi.concourse.annotate.DoNotInvoke; import com.cinchapi.concourse.annotate.Restricted; @@ -58,7 +59,6 @@ import com.cinchapi.concourse.thrift.TObject; import com.cinchapi.concourse.time.Time; import com.cinchapi.concourse.util.Logger; -import com.cinchapi.concourse.util.Strings; import com.google.common.base.MoreObjects; import com.google.common.cache.Cache; import com.google.common.cache.CacheBuilder; @@ -1039,7 +1039,7 @@ private class BufferTransportThread extends Thread { * Construct a new instance. */ public BufferTransportThread() { - super(Strings.joinSimple("BufferTransport [", environment, "]")); + super(AnyStrings.joinSimple("BufferTransport [", environment, "]")); setDaemon(true); setPriority(MIN_PRIORITY); setUncaughtExceptionHandler(new UncaughtExceptionHandler() { diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Stores.java b/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Stores.java index 2400430bed..2487e43dd8 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Stores.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/server/storage/Stores.java @@ -17,11 +17,11 @@ import javax.annotation.concurrent.Immutable; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.concourse.Link; import com.cinchapi.concourse.thrift.Operator; import com.cinchapi.concourse.thrift.TObject; import com.cinchapi.concourse.util.Convert; -import com.cinchapi.concourse.util.Strings; import com.cinchapi.concourse.util.TStrings; import com.cinchapi.concourse.validate.Keys; @@ -103,7 +103,7 @@ public static OperationParameters operationalize(Operator operator, public static void validateWriteData(String key, TObject value) { // CON-21 if(!Keys.isWritable(key)) { throw new IllegalArgumentException( - Strings.joinWithSpace(key, "is not a valid key")); + AnyStrings.joinWithSpace(key, "is not a valid key")); } else if(value.isBlank()) { throw new IllegalArgumentException( diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/util/Commands.java b/concourse-server/src/main/java/com/cinchapi/concourse/util/Commands.java index ba85e01887..0deb9b61ed 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/util/Commands.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/util/Commands.java @@ -20,6 +20,8 @@ import spark.utils.IOUtils; import com.cinchapi.common.base.CheckedExceptions; +import com.cinchapi.common.base.SplitOption; +import com.cinchapi.common.base.StringSplitter; /** * Abstractions for system commands. diff --git a/concourse-server/src/main/java/com/cinchapi/concourse/util/TStrings.java b/concourse-server/src/main/java/com/cinchapi/concourse/util/TStrings.java index f001997b9d..e6de08b8f6 100644 --- a/concourse-server/src/main/java/com/cinchapi/concourse/util/TStrings.java +++ b/concourse-server/src/main/java/com/cinchapi/concourse/util/TStrings.java @@ -19,6 +19,8 @@ import org.apache.commons.lang.StringUtils; +import com.cinchapi.common.base.AnyStrings; +import com.cinchapi.common.base.StringSplitter; import com.cinchapi.concourse.server.GlobalState; import com.google.common.collect.Lists; @@ -79,7 +81,7 @@ public static boolean isInfixSearchMatch(String[] needle, } String n = needle[npos]; String h = haystack[hpos]; - if(Strings.isSubString(n, h)) { + if(AnyStrings.isSubString(n, h)) { ++npos; ++hpos; } diff --git a/concourse-server/src/test/java/com/cinchapi/concourse/server/http/EndpointContainerTest.java b/concourse-server/src/test/java/com/cinchapi/concourse/server/http/EndpointContainerTest.java index c3a0cb2a1e..78f6ae1210 100644 --- a/concourse-server/src/test/java/com/cinchapi/concourse/server/http/EndpointContainerTest.java +++ b/concourse-server/src/test/java/com/cinchapi/concourse/server/http/EndpointContainerTest.java @@ -21,7 +21,7 @@ import org.junit.Assert; import org.junit.Test; -import com.cinchapi.concourse.util.Strings; +import com.cinchapi.common.base.AnyStrings; /** * Unit tests for {@link HttpPlugin}. @@ -67,7 +67,7 @@ public void testGetCanonicalNamespaceAliasModule() { @Test public void testBuildSparkPath() { Assert.assertEquals(":key/:record/audit", - buildSparkPath(Strings.splitCamelCase("$Key$RecordAudit"))); + buildSparkPath(AnyStrings.splitCamelCase("$Key$RecordAudit"))); } } diff --git a/concourse-server/src/test/java/com/cinchapi/concourse/util/TMapsTest.java b/concourse-server/src/test/java/com/cinchapi/concourse/util/TMapsTest.java index b8732a275a..fbf4a2f7f8 100644 --- a/concourse-server/src/test/java/com/cinchapi/concourse/util/TMapsTest.java +++ b/concourse-server/src/test/java/com/cinchapi/concourse/util/TMapsTest.java @@ -24,6 +24,7 @@ import org.junit.Assert; import org.junit.Test; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.profile.Benchmark; import com.cinchapi.concourse.server.plugin.data.TObjectResultDataset; import com.cinchapi.concourse.thrift.TObject; @@ -98,12 +99,12 @@ public void action() { latch.await(); double datasetTimeDigits = Math.ceil(Math.log10(datasetTime.get())); double mapTimeDigits = Math.ceil(Math.log10(mapTime.get())); - System.out.println(Strings.format("Dataset = {} {} with {} digits", + System.out.println(AnyStrings.format("Dataset = {} {} with {} digits", datasetTime.get(), unit, datasetTimeDigits)); - System.out.println(Strings.format("Map = {} {} with {} digits", + System.out.println(AnyStrings.format("Map = {} {} with {} digits", mapTime.get(), unit, mapTimeDigits)); Assert.assertTrue( - Strings.format("Datset took {} {} and Map took {} {}", + AnyStrings.format("Datset took {} {} and Map took {} {}", datasetTime.get(), unit, mapTime.get(), unit), datasetTimeDigits - mapTimeDigits <= 1); diff --git a/concourse-shell/src/main/java/com/cinchapi/concourse/shell/ConcourseShell.java b/concourse-shell/src/main/java/com/cinchapi/concourse/shell/ConcourseShell.java index 2c43b5b30a..9a2ecfd51b 100644 --- a/concourse-shell/src/main/java/com/cinchapi/concourse/shell/ConcourseShell.java +++ b/concourse-shell/src/main/java/com/cinchapi/concourse/shell/ConcourseShell.java @@ -46,6 +46,7 @@ import com.beust.jcommander.JCommander; import com.beust.jcommander.Parameter; +import com.cinchapi.common.base.AnyStrings; import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.concourse.Concourse; import com.cinchapi.concourse.Link; @@ -353,8 +354,7 @@ private static String getHelpText(String topic) { private static String tryGetCorrectApiMethod(String alias) { String camel = CaseFormat.LOWER_UNDERSCORE.to(CaseFormat.LOWER_CAMEL, alias); - String expanded = com.cinchapi.concourse.util.Strings - .ensureStartsWith(camel, "concourse."); + String expanded = AnyStrings.ensureStartsWith(camel, "concourse."); return methods.contains(expanded) && !camel.equals(alias) ? camel : null; } From b1f651690a5b9280b93953dee99c241e100b95cd Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Sat, 16 Feb 2019 18:11:00 -0500 Subject: [PATCH 02/10] Remove deprecated classes --- .../util/QuoteAwareStringSplitter.java | 139 ------ .../cinchapi/concourse/util/SplitOption.java | 99 ---- .../concourse/util/StringSplitter.java | 445 ------------------ .../com/cinchapi/concourse/util/Strings.java | 400 ---------------- 4 files changed, 1083 deletions(-) delete mode 100644 concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java delete mode 100644 concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java delete mode 100644 concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java delete mode 100644 concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java deleted file mode 100644 index f41f5bf4b2..0000000000 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/QuoteAwareStringSplitter.java +++ /dev/null @@ -1,139 +0,0 @@ -/* - * Copyright (c) 2013-2019 Cinchapi Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.cinchapi.concourse.util; - -/** - * A {@link StringSplitter} that does not split on a delimiter if it falls - * between single or double quotes - * - * @author Jeff Nelson - * @deprecated use {@link com.cinchapi.common.base.QuoteAwareStringSplitter} - * instead - */ -@Deprecated -public class QuoteAwareStringSplitter extends StringSplitter { - - /** - * A flag that indicates whether the splitter is in the middle of a single - * quoted token. - */ - private boolean inSingleQuote = false; - - /** - * A flag that indicates whether the splitter is in the middle of a double - * quoted token. - */ - private boolean inDoubleQuote = false; - - /** - * We keep track of the previously seen char so we can determine in the - * instance of a single quote is really an apostrophe or the beginning of a - * quoted token. - */ - private char previousChar = ' '; - - /** - * The position where the most recent single quote character was found. We - * keep track of this in case the single quote was actually an apostrophe. - */ - private int singleQuotePos = -1; - - /** - * Construct a new instance. - * - * @param string string the string to split - */ - public QuoteAwareStringSplitter(String string) { - super(string); - } - - /** - * Construct a new instance. - * - * @param string string the string to split - * @param options an array of {@link SplitOption options} to supplement the - * split behaviour - */ - public QuoteAwareStringSplitter(String string, SplitOption... options) { - super(string, options); - } - - /** - * Construct a new instance. - * - * @param string string the string to split - * @param delimiter the delimiter upon which to split - */ - public QuoteAwareStringSplitter(String string, char delimiter) { - super(string, delimiter); - } - - /** - * Construct a new instance. - * - * @param string string the string to split - * @param delimiter the delimiter upon which to split - * @param options an array of {@link SplitOption options} to supplement the - * split behaviour - */ - public QuoteAwareStringSplitter(String string, char delimiter, - SplitOption... options) { - super(string, delimiter, options); - } - - @Override - protected boolean isReadyToSplit() { - assert (inSingleQuote && inDoubleQuote) == false; // assert that we are - // never both in the - // context of having - // both single and - // double quotes - return !inSingleQuote && !inDoubleQuote; - } - - @Override - protected void updateIsReadyToSplit(char c) { - if(previousChar != '\\' && c == '\'' && !inDoubleQuote && (inSingleQuote - || (!inSingleQuote && !Character.isLetter(previousChar)))) { - // Assumes that occurrence of single quote only means single quote - // if the previous char was not a letter (in which case we assume - // the single quote is actually an apostrophe) - inSingleQuote ^= true; - singleQuotePos = pos - 1; - } - else if(previousChar != '\\' && c == '"' && !inSingleQuote) { - inDoubleQuote ^= true; - } - previousChar = c; - } - - @Override - public boolean confirmSetNext() { - if(inSingleQuote) { - // If an attempt is made to set the next while we are in a single - // quote we must backtrack because the single quote was actually an - // apostrophe - inSingleQuote = false; - pos = singleQuotePos + 1; - singleQuotePos = -1; - return false; - } - else { - return super.confirmSetNext(); - } - } - -} diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java deleted file mode 100644 index 20a6e3e43b..0000000000 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/SplitOption.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * Copyright (c) 2013-2019 Cinchapi Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.cinchapi.concourse.util; - -/** - * An option that can be passed to a {@link StringSplitter} to specify - * additional split behaviour to supplement the delimiter (i.e. always splitting - * on a newline). - * - * @author Jeff Nelson - */ -@Deprecated -public enum SplitOption { - /** - * Split on a newline character sequence (\n, \r\n, \r) in addition to - * splitting on the delimiter. This is useful for simulating the reading a - * string, line by line while also splitting on delimiters within that line - * without traversing the string multiple times. - */ - SPLIT_ON_NEWLINE(0), - - /** - * In addition to splitting on the delimiter, split on an any kind of - * parenthesis and return the same as an individual token. - */ - TOKENIZE_PARENTHESIS(1), - - /** - * For the {@link QuoteAwareStringSplitter} drop any quotes that surround a - * quoted sequence that may contain a delimiter. - */ - DROP_QUOTES(2), - - /** - * Trim any leading and trailing whitespace from each token. - */ - TRIM_WHITESPACE(3); - - /** - * A constant that signifies no split options should be passed to the - * {@link StringSplitter}. - */ - public static SplitOption[] NONE = new SplitOption[] {}; - - /** - * The bit mask to use when flipping/checking the appropriate bit to - * determine if this option is enabled. - */ - private final int mask; - - /** - * Construct a new instance. - * - * @param mask - */ - private SplitOption(int mask) { - this.mask = mask; - } - - /** - * Return the bit mask for this {@link SplitOption}. Always use this as - * opposed to {@link #ordinal()}. - * - * @return the bit mask - */ - public int mask() { - return mask; - } - - /** - * Given a {@link StringSplitter} instance, check to see if this - * {@link SplitOption option} is enabled. An option can be enabled by - * passing it to the - * {@link StringSplitter#StringSplitter(String, char, SplitOption...) - * constructor}. - * - * @param splitter the {@link StringSplitter} to check - * @return {@code true} if the bit corresponding to this option is set in - * {@code options} - */ - public boolean isEnabled(StringSplitter splitter) { - // splitter.options is the value that results from enabling the - // appropriate bits for all the enabled values. - return (splitter.options & (1 << mask)) != 0; - } -} diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java deleted file mode 100644 index 72b80e1831..0000000000 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/StringSplitter.java +++ /dev/null @@ -1,445 +0,0 @@ -/* - * Copyright (c) 2013-2019 Cinchapi Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.cinchapi.concourse.util; - -import static com.cinchapi.concourse.util.SplitOption.*; - -import java.util.List; -import java.util.NoSuchElementException; - -import com.google.common.collect.Lists; - -/** - * An in-place utility to traverse and split a string into substring. - *

- * Unlike the {@link String#split(String)} method, this utility returns tokens - * as they are split on the fly so the caller can process them in place. The - * traditional {@link String#split(String)} approach must make at least two - * passes over the string [O(n^2)] whereas this approach is guarantee to make a - * single pass [O(n)]. - *

- *

- *

Usage

- * - *
- * String string = "Please split this string by space";
- * StringSplitter splitter = new StringSplitter(string);
- * while (splitter.hasNext()) {
- *     String next = splitter.next();
- * }
- * 
- * - *

- * - * @author Jeff Nelson - * @deprecated use {@link com.cinchapi.common.base.StringSplitter} instead - */ -@Deprecated -public class StringSplitter { - - /** - * An integer that contains bits representing {@link SplitOption split - * options} that have been enabled. To check whether an option is enabled do - * - *
-     * return (options & (1 << option.mask())) != 0;
-     * 
- */ - protected final int options; - - /** - * The current position of the splitter. - */ - protected int pos = 0; - - /** - * The char array of the string that is being split. - */ - private char[] chars; - - /** - * The delimiter to use for splitting. - */ - private final char delimiter; - - /** - * A flag that controls whether an attempt to split on a newline character - * sequence should ignore the line feed character ('\n') because the - * previous character was a carriage return (\r). Typically, a sequence of - * \r\n is used by Windows to signify a newline. - * - *

- * This flag is only relevant if the option to {@link #splitOnNewline()} is - * enabled. - *

- */ - private boolean ignoreLF = false; - - /** - * A flag that is set in the {@link #next()} method whenever it grabs a - * {@link #next} token that was determined to be at the end of line. This - * means that calls to {@link #atEndOfLine()} will return {@code true} until - * the next call to {@link #next()}. - */ - private boolean lastEOL = false; - - /** - * The next string to return. - */ - private String next = null; - - /** - * A flag that is set in the {@link #findNext()} method whenever it - * determines that the {@link #next} token to be returned is at the end of - * line. - */ - private boolean nextEOL = false; - - /** - * A flag that controls whether we should allow {@link #findNext()} to set - * {@link #next} to an empty string. Normally, whenever two delimiters - * appear back to back, the splitter will return an empty string (i.e. - * "foo,,bar,car" means that there is an empty token in the 2nd column). - * However, when additional {@link #options} are passed to the splitter, it - * may be unintuitive to return an empty string when we a character that is - * relevant for one of the options and the delimiter appear back-to-back. - */ - private boolean overrideEmptyNext = false; - - /** - * The start of the next token. - */ - private int start = 0; - - /** - * Construct a new instance. - * - * @param string the string to split - */ - public StringSplitter(String string) { - this(string, ' '); - } - - /** - * Construct a new instance. - * - * @param string the string to split - * @param delimiter the delimiter upon which to split - */ - public StringSplitter(String string, char delimiter) { - this(string, delimiter, SplitOption.NONE); - } - - /** - * Construct a new instance. - * - * @param string the string to split - * @param delimiter the delimiter upon which to split - * @param options an array of {@link SplitOption options} to supplement the - * split behaviour - */ - public StringSplitter(String string, char delimiter, - SplitOption... options) { - this.chars = string.toCharArray(); - this.delimiter = delimiter; - int opts = 0; - for (SplitOption option : options) { - opts |= 1 << option.mask(); - } - this.options = opts; - findNext(); - } - - /** - * Construct a new instance. - * - * @param string the string to split - * @param options an array of {@link SplitOption options} to supplement the - * split behaviour - */ - public StringSplitter(String string, SplitOption... options) { - this(string, ' ', options); - } - - /** - * Return {@code true} if {@link SplitOption#SPLIT_ON_NEWLINE} is - * {@link SplitOption#isEnabled(StringSplitter) enabled} and the last token - * returned by {@link #next()} is followed immediately by a line break. - * Otherwise, return {@code false}. - * - * @return {@code true} if the last token returned was at the end of line - */ - public boolean atEndOfLine() { - return lastEOL; - } - - /** - * Return {@code true} if this splitter has any remaining substrings. - * - * @return {@code true} if there is another element - */ - public boolean hasNext() { - return next != null; - } - - /** - * Return the next substring that results from splitting the original source - * string. - * - * @return the new substring - */ - public String next() { - if(next == null) { - throw new NoSuchElementException(); - } - else { - String result = next; - if(lastEOL) { - lastEOL = false; - } - if(nextEOL) { - lastEOL = true; - nextEOL = false; - } - findNext(); - return result; - } - } - - /** - * Reset the splitter. - */ - public void reset() { - pos = 0; - start = 0; - } - - /** - * Return an array that contains all the tokens after traversing through the - * entire split process. - * - * @return the tokens - */ - public String[] toArray() { - List toks = Lists.newArrayList(); - while (hasNext()) { - toks.add(next()); - } - return toks.toArray(new String[0]); - } - - /** - * Before an attempt is made to {@link #setNext() set the next token} do - * some analysis on the internal state of the splitter to see if its - * actually appropriate to do so. If the next token should not be set, - * return {@code false} from this method and also optionally change the - * {@link #pos} pointer to rewind the splitter. - * - * @return {@code true} if the splitter is indeed ready to set the next - * token - */ - protected boolean confirmSetNext() { - return true; - } - - /** - * Determine, based on state factors that are recorded within the class, if - * the splitter is actually ready to split the string on an instance of the - * delimiter. By default, this method always returns {@code true}, but a - * subclass can use it for awareness of certain conditions that would mean a - * string should not be split on an instance of the delimiter (i.e. if the - * delimiter occurs within quotes). - * - * @return {@code true} if the splitter is actually ready to perform a split - */ - protected boolean isReadyToSplit() { - return true; - } - - /** - * Given a character {@code c} that is processed by the splitter, update the - * state that determines whether the splitter would actually be ready to - * split in the event that it encounters a delimiter character. - * - * @param c - */ - protected void updateIsReadyToSplit(char c) {/* noop */} - - /** - * Find the next element to return. - */ - private void findNext() { - nextEOL = false; - next = null; - boolean resetOverrideEmptyNext = true; - boolean processOverrideEmptyNext = true; - while (pos < chars.length && next == null) { - boolean resetIgnoreLF = true; - char c = chars[pos]; - ++pos; - if(c == delimiter && isReadyToSplit()) { - setNext(); - } - else if(SPLIT_ON_NEWLINE.isEnabled(this) && c == '\n' - && isReadyToSplit()) { - if(ignoreLF) { - start = pos; - } - else { - setNext(); - nextEOL = true; - } - } - else if(SPLIT_ON_NEWLINE.isEnabled(this) && c == '\r' - && isReadyToSplit()) { - ignoreLF = true; - resetIgnoreLF = false; - setNext(); - nextEOL = true; - } - else if(TOKENIZE_PARENTHESIS.isEnabled(this) - && (c == '(' || c == ')') && isReadyToSplit()) { - setNext(); - if(next.isEmpty()) { - next = Strings.valueOfCached(c); - overrideEmptyNext = true; - processOverrideEmptyNext = false; - resetOverrideEmptyNext = false; - } - else { - // Need to undo the modifications from #setNext() in order - // to look at the parenthesis char again so it can be - // returned as a single token via the if block above - pos--; - start = pos; - } - } - // For SPLIT_ON_NEWLINE, we must reset #ignoreLF if the current char - // is not == '\r' - ignoreLF = resetIgnoreLF ? false : ignoreLF; - updateIsReadyToSplit(c); - } - if(pos == chars.length && next == null) { // If we reach the end of the - // string without finding - // the delimiter, then set - // next to be all the - // remaining chars. - if(confirmSetNext()) { - int length = pos - start; - if(length == 0) { - next = ""; - } - else { - length = trim(length); - next = String.valueOf(chars, start, length); - } - ++pos; - } - else { - findNext(); - } - } - if(next != null && next.isEmpty()) { - // For compatibility with String#split, we must detect if an empty - // token occurs at the end of a string by trying to find the next - // occurrence of a non delimiter char. - boolean atEnd = true; - for (int i = pos; i < chars.length; ++i) { - if(chars[i] != delimiter) { - atEnd = false; - break; - } - } - next = atEnd ? null : next; - } - // FOR TOKENIZE_PARENTHESIS, we must #overrideEmptyNext if the last - // next was a single parenthesis in case the next char is a delimiter. - // This prevents the appearance of having back-to-back delimiters. - if(overrideEmptyNext && processOverrideEmptyNext) { - if(next != null && next.isEmpty()) { - findNext(); - } - resetOverrideEmptyNext = true; - } - overrideEmptyNext = resetOverrideEmptyNext ? false : overrideEmptyNext; - if(next != null && DROP_QUOTES.isEnabled(this) - && Strings.isWithinQuotes(next) - && this instanceof QuoteAwareStringSplitter) { - next = next.substring(1, next.length() - 1); - } - } - - /** - * Set the {@link #next} element based on the current {@link #pos} and the - * {@link #start} of the search. - *

- * The side effects of this method are: - *

    - *
  • {@code next} is set equal to all the chars from {@link #start} and - * {@link #pos} - 2
  • - *
  • {@code start} is set equal to {@link #pos}
  • - * The char at {@link #pos} - 1 is "dropped". This character is usually - * the delimiter, so it is okay to do this, but if there is a corner case, - * the caller must explicitly handle that character - *
- *

- */ - private void setNext() { - if(confirmSetNext()) { - int length = pos - start - 1; - if(length == 0) { - next = ""; - } - else { - length = trim(length); - next = String.valueOf(chars, start, length); - } - start = pos; - } - else { - findNext(); - } - } - - /** - * Given the desired {@code length} for the {@link #next} token, perform any - * trimming of leading and trailing white space if - * {@link SplitOption#TRIM_WHITESPACE} - * {@link SplitOption#isEnabled(StringSplitter) is enabled}. - *

- * This method will modify the global {@link #start} position for the - * {@link #next} string. It returns the appropriate length to assign after - * the trimming has been done. - *

- * - * @param length the length of the untrimmed {@link #next} string. - * @return the appropriate length after the trimming - */ - private int trim(int length) { - if(SplitOption.TRIM_WHITESPACE.isEnabled(this)) { - while (Character.isWhitespace(chars[start]) && length > 1) { - start++; - length--; - } - while (Character.isWhitespace(chars[(start + length) - 1]) - && length > 1) { - length--; - } - } - return length; - } - -} \ No newline at end of file diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java deleted file mode 100644 index e96d03c9f3..0000000000 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Strings.java +++ /dev/null @@ -1,400 +0,0 @@ -/* - * Copyright (c) 2013-2019 Cinchapi Inc. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.cinchapi.concourse.util; - -import java.util.List; -import java.util.Set; - -import javax.annotation.Nullable; - -import com.cinchapi.common.base.AnyStrings; -import com.google.gson.JsonParseException; - -/** - * Yet another collection of utility functions for Strings that tries to add new - * functionality or optimize existing ones. - * - * @author Jeff Nelson - * @deprecated in version 0.9.6; use {@link AnyStrings} instead - */ -@Deprecated -public final class Strings { - - /** - * Ensure that {@code string} ends with {@code suffix} by appending it to - * {@code string} if and only if it is not already the last sequence of - * characters in the string. - * - * @param string the {@link String} to that should end with {@code suffix} - * @param suffix the {@link String} of characters with which {@code string} - * should end - * @return {@code string} if it already ends with {@code suffix} or a new - * {@link String} that contains {@code suffix} appended to - * {@code string} - */ - public static String ensureEndsWith(String string, String suffix) { - return AnyStrings.ensureEndsWith(string, suffix); - } - - /** - * Ensure that {@code string} starts with {@code prefix} by prepending it to - * {@code string} if and only if it is not already the first sequence of - * characters in the string. - * - * @param string the {@link String} to that should start with {@code prefix} - * @param prefix the {@link String} of characters with which {@code string} - * should start - * @return {@code string} if it already begins with {@code prefix} or a new - * {@link String} that contains {@code prefix} prepended to - * {@code string} - */ - public static String ensureStartsWith(String string, String prefix) { - return AnyStrings.ensureStartsWith(string, prefix); - } - - /** - * Ensure that {@code string} is surrounded by quotes. If that is not the - * case, alter the string so that it is and return the altered form. - * - *

- * Calling {@link Strings#isWithinQuotes(String)} on the result of this - * method will always return {@code true}. - *

- * - * @param string the string that must be quoted - * @return {@code string} or {@code string} surrounded by quotes if it is - * not already - */ - public static String ensureWithinQuotes(String string) { - return AnyStrings.ensureWithinQuotes(string); - } - - /** - * Wrap {@code string} within quotes if it is necessary to do so. Otherwise, - * return the original {@code string}. - * - *

- * The original {@code string} will be wrapped in quotes and returned as - * such if: - *

    - *
  • it is not already wrapped {@link #isWithinQuotes(String) within - * quotes}, and
  • - *
  • {@code delimiter} appears at least once
  • - *
- * If those conditions are met, the original string will be wrapped in - * either - *
    - *
  • double quotes if a single quote appears in the original string, - * or
  • - *
  • single quotes if a double quote appears in the original string, - * or
  • - *
  • double quotes if both a single and double quote appear in the - * original string; furthermore, all instances of double quotes within the - * original string will be escaped
  • - *
- *

- * - * @param string the string to potentially quote - * @param delimiter the delimiter that determines whether quoting should - * happen - * @return the original {@code string} or a properly quoted alternative - */ - public static String ensureWithinQuotesIfNeeded(String string, - char delimiter) { - return AnyStrings.ensureWithinQuotesIfNeeded(string, delimiter); - } - - /** - * Efficiently escape inner occurrences of each of the {@code characters} - * within the {@code string}, if necessary. - *

- * Escaped characters are prepended with the backslash ('\') character. - *

- *

- * An "inner occurrence" for a character is one that is not at the head or - * tail of the string. - *

- * - * @param string the string to escape - * @param characters the characters to escape within the {@code string} - * @return the escaped {@code string} - */ - public static String escapeInner(String string, char... characters) { - return AnyStrings.escapeInner(string, characters); - } - - /** - * Replace all instances of "confusable" unicode characters with a - * canoncial/normalized character. - *

- * See http://www.unicode.org/Public/security/revision-03/confusablesSummary. - * txt for a list of characters that are considered to be confusable. - *

- * - * @param string the {@link String} in which the replacements should occur - * @return a {@link String} free of confusable unicode characters - */ - public static String replaceUnicodeConfusables(String string) { - return AnyStrings.replaceUnicodeConfusables(string); - } - - /** - * Perform string substitution and formatting in a manner that is similar to - * the SLF4J library. - * - *
-     * Strings#format("Bob is very {} because he has no {}", "brave", "fear") = "Bob is very brave because he has no fear"
-     * 
- *

- * NOTE: This method is less efficient than using a - * {@link StringBuilder} and manually appending variable arguments for - * interpolation. This is provided for convenience, but don't use it for - * anything that is performance critical. - *

- * - * @param pattern the message pattern which will be parsed and formatted - * @param params an array of arguments to be substituted in place of - * formatting anchors - * @return The formatted message - */ - public static String format(String pattern, Object... params) { - return AnyStrings.format(pattern, params); - } - - /** - * Return a set that contains every possible substring of {@code string} - * excluding pure whitespace strings. - * - * @param string the string to divide into substrings - * @return the set of substrings - */ - public static Set getAllSubStrings(String string) { - return AnyStrings.getAllSubStrings(string); - } - - /** - * An optimized version of {@link String#contains(CharSequence)} to see if - * {@code needle} is a substring of {@code haystack}. - * - * @param needle the substring for which to search - * @param haystack the string in which to search for the substring - * @return {@code true} if {@code needle} is a substring - */ - public static boolean isSubString(String needle, String haystack) { - return AnyStrings.isSubString(needle, haystack); - } - - /** - * Return {@code true} if the {@code json} string is valid, otherwise return - * {@code false}. - * - * @param json a json formatted string - * @return {@code true} if the {@code json} is valid - * @deprecated in version 0.9.6; use - * {@link com.cinchapi.concourse.util.DataServices#jsonParser()#parse()} - */ - @Deprecated - public static boolean isValidJson(String json) { - char first = json.charAt(0); - char last = json.charAt(json.length() - 1); - if((first == '[' || first == '{') && (last == ']' || last == '}')) { - try { - DataServices.jsonParser().parse(json); - return true; - } - catch (JsonParseException e) { - return false; - } - } - else { - return false; - } - } - - /** - * Return {@code true} if {@code string} both starts and ends with single or - * double quotes. - * - * @param string - * @return {@code true} if the string is between quotes - */ - public static boolean isWithinQuotes(String string) { - return AnyStrings.isWithinQuotes(string); - } - - /** - * Concatenates the {@link Object#toString string} representation of all the - * {@code args}, separated by the {@code separator} char in an efficient - * manner. - * - * @param separator the separator to place between each of the {@code args} - * @param args the args to join - * @return the resulting String - */ - public static String join(char separator, Object... args) { - return AnyStrings.join(separator, args); - } - - /** - * Concatenates the {@link Object#toString string} representation of all the - * {@code args}, separated by the {@code separator} string in an efficient - * manner. - * - * @param separator the separator to place between each of the {@code args} - * @param args the args to join - * @return the resulting String - */ - public static String join(String separator, Object... args) { - return AnyStrings.join(separator, args); - } - - /** - * Concatenates the toString values of all the {@code args} in an efficient - * manner. - * - * @param args - * @return the resulting String - */ - public static String joinSimple(Object... args) { - return AnyStrings.joinSimple(args); - } - - /** - * Concatenates the toString values of all the {@code args}, separated by - * whitespace in an efficient manner. - * - * @param args - * @return the resulting String - */ - public static String joinWithSpace(Object... args) { - return AnyStrings.joinWithSpace(args); - } - - /** - * Split a string, using whitespace as a delimiter, as long as the - * whitespace is not wrapped in double or single quotes. - * - * @param string - * @return the tokens that result from the split - * @deprecated in version 0.5.0, use {@link QuoteAwareStringSplitter} - * instead. - */ - @Deprecated - public static String[] splitButRespectQuotes(String string) { - return AnyStrings.splitButRespectQuotes(string); - } - - /** - * Split a camel case {@code string} into tokens that represent the distinct - * words. - *

- *

Example

- *
    - * thisIsACamelCaseSTRING -> [this, Is, A, Camel, Case, S, T, R, I, N, G] - *
- *
    - * ThisIsACamelCaseSTRING -> [This, Is, A, Camel, Case, S, T, R, I, N, G] - *
- *
    - * thisisacamelcasestring -> [thisisacamelcasestring] - *
- *

- * - * @param string - * @return a list of tokens after splitting the string on camel case word - * boundaries - */ - public static List splitCamelCase(String string) { - return AnyStrings.splitCamelCase(string); - } - - /** - * Split a string on a delimiter as long as that delimiter is not wrapped in - * double or single quotes. - *

- * If {@code delimiter} is a single character string, it is more efficient - * to use a {@link StringSplitter} as opposed to this method. - *

- * - * @param string the string to split - * @param delimiter the delimiting string/regex on which the input - * {@code string} is split - * @return the tokens that result from the split - */ - public static String[] splitStringByDelimiterButRespectQuotes(String string, - String delimiter) { - return AnyStrings.splitStringByDelimiterButRespectQuotes(string, - delimiter); - } - - /** - * This method efficiently tries to parse {@code value} into a - * {@link Boolean} object if possible. If the string is not a boolean, then - * the method returns {@code null} as quickly as possible. - * - * @param value - * @return a Boolean object that represents the string or {@code null} if it - * is not possible to parse the string into a boolean - */ - public static Boolean tryParseBoolean(String value) { - return AnyStrings.tryParseBoolean(value); - } - - /** - * This method efficiently tries to parse {@code value} into a - * {@link Number} object if possible. If the string is not a number, then - * the method returns {@code null} as quickly as possible. - * - * @param value - * @return a Number object that represents the string or {@code null} if it - * is not possible to parse the string into a number - */ - @Nullable - public static Number tryParseNumber(String value) { - return AnyStrings.tryParseNumber(value); - } - - /** - * A stricter version of {@link #tryParseNumber(String)} that does not parse - * strings that masquerade as numbers (i.e. 3.124D). Instead this method - * will only parse the string into a Number if it contains characters that - * are either a decimal digit, a decimal separator or a negative sign. - * - * @param value - * @return a Number object that represents the string or {@code null} if it - * is not possible to parse the string into a number - */ - @Nullable - public static Number tryParseNumberStrict(String value) { - return AnyStrings.tryParseNumberStrict(value); - } - - /** - * Similar to the {@link String#valueOf(char)} method, but this one will - * return a cached copy of the string for frequently used characters. - * - * @param c the character to convert - * @return a string of length 1 containing the input char - */ - public static String valueOfCached(char c) { - return AnyStrings.valueOfCached(c); - } - - private Strings() {/* noop */} - -} \ No newline at end of file From c6df784882541c072a1c63fb6a48729aaa17119a Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Sat, 16 Feb 2019 18:52:05 -0500 Subject: [PATCH 03/10] upgrade lib-config to fix failing unit tests --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 1da84dc0d0..01e27b7ca3 100644 --- a/build.gradle +++ b/build.gradle @@ -110,7 +110,7 @@ subprojects { compile 'org.apache.thrift:libthrift:0.9.3' compile 'commons-configuration:commons-configuration:1.9' compile group: 'com.cinchapi', name: 'accent4j', version: '1.5.3', changing:true - compile 'com.cinchapi:lib-config:1.3.1' + compile 'com.cinchapi:lib-config:1.5.1' testCompile 'junit:junit:4.11' } From bc58cf54d9cc40160db3fccb2792e0b16e463de0 Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Sat, 16 Feb 2019 20:25:31 -0500 Subject: [PATCH 04/10] upgrade bucket module to 1.5.0 to fix unti test failure --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 01e27b7ca3..0c0dcfb180 100644 --- a/build.gradle +++ b/build.gradle @@ -125,7 +125,7 @@ subprojects { version = globalVersion // Versions for some shared (but non-global) dependencies - ext.bucketVersion = '1.4.1' + ext.bucketVersion = '1.5.0' // Drop the build component from version number and use that for // publishing From 06e08f4ea3de8413a14180a51464830b0ae64165 Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Sat, 16 Feb 2019 21:02:34 -0500 Subject: [PATCH 05/10] CON-635: Add support for Criteria containing all Unicode quote characters (#357) * stage changes * upgrade CCL module to 2.5.2 * javadoc update * update changelog --- CHANGELOG.md | 1 + concourse-driver-java/build.gradle | 2 +- .../com/cinchapi/concourse/lang/Language.java | 11 ++++- .../cinchapi/concourse/bugrepro/CON635.java | 46 +++++++++++++++++++ 4 files changed, 58 insertions(+), 2 deletions(-) create mode 100644 concourse-integration-tests/src/test/java/com/cinchapi/concourse/bugrepro/CON635.java diff --git a/CHANGELOG.md b/CHANGELOG.md index c45c09f976..7dab080f1e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ #### Version 0.9.6 (TBD) * Fixed a bug that caused a `ParseException` to be thrown when trying to use a `Criteria` object containing a string value wrapped in single or double quotes out of necessity (i.e. because the value contained a keyword). This bug happened because the wrapping quotes were dropped by Concourse Server when parsing the `Criteria`. +* Fixed a bug where the CCL parser failed to handle some Unicode quote characters. #### Version 0.9.5 (December 30, 2018) * Fixed a bug where some of the `ManagedConcourseServer#get` methods in the `concourse-ete-test-core` package called the wrong upstream method of the Concourse Server instance under management. This had the effect of causing a runtime `ClassCastException` when trying to use those methods. diff --git a/concourse-driver-java/build.gradle b/concourse-driver-java/build.gradle index 7de10443ed..76ca9b2970 100644 --- a/concourse-driver-java/build.gradle +++ b/concourse-driver-java/build.gradle @@ -25,7 +25,7 @@ dependencies { compile 'org.slf4j:log4j-over-slf4j:1.7.5' compile 'org.slf4j:jcl-over-slf4j:1.7.5' compile 'com.google.code.gson:gson:2.5' - compile group: 'com.cinchapi', name: 'ccl', version:'2.5.1' + compile group: 'com.cinchapi', name: 'ccl', version:'2.5.2' testCompile project(':concourse-unit-test-core') testCompile 'com.github.marschall:memoryfilesystem:0.9.0' diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java index fc41344e3d..34269c2ad0 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java @@ -26,6 +26,7 @@ import com.cinchapi.ccl.grammar.TimestampSymbol; import com.cinchapi.ccl.grammar.ValueSymbol; import com.cinchapi.common.base.AnyStrings; +import com.cinchapi.common.reflect.Reflection; import com.cinchapi.concourse.thrift.TCriteria; import com.cinchapi.concourse.thrift.TSymbol; import com.cinchapi.concourse.thrift.TSymbolType; @@ -39,6 +40,13 @@ */ public final class Language { + /** + * The character that indicates a String should be treated as a + * {@link com.cinchapi.concourse.Tag}. + */ + private static final char TAG_MARKER = Reflection.getStatic("TAG_MARKER", + Convert.class); // (authorized) + /** * Translate the {@link TSymbol} to its Java analog. * @@ -55,7 +63,8 @@ else if(tsymbol.getType() == TSymbolType.KEY) { else if(tsymbol.getType() == TSymbolType.VALUE) { Object symbol = Convert.stringToJava(tsymbol.getSymbol()); if(symbol instanceof String && !symbol.equals(tsymbol.getSymbol()) - && AnyStrings.isWithinQuotes(tsymbol.getSymbol())) { + && AnyStrings.isWithinQuotes(tsymbol.getSymbol(), + TAG_MARKER)) { // CON-634: This is an obscure corner case where the surrounding // quotes on the original tsymbol were necessary to escape a // keyword, but got dropped because of the logic in diff --git a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/bugrepro/CON635.java b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/bugrepro/CON635.java new file mode 100644 index 0000000000..836036e406 --- /dev/null +++ b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/bugrepro/CON635.java @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2013-2019 Cinchapi Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.cinchapi.concourse.bugrepro; + +import org.junit.Assert; +import org.junit.Test; + +import com.cinchapi.concourse.lang.Criteria; +import com.cinchapi.concourse.test.ConcourseIntegrationTest; +import com.cinchapi.concourse.thrift.Operator; + +/** + * Repro of http://jira.cinchapi.com/browse/CON-635 + * + * @author Jeff Nelson + */ +public class CON635 extends ConcourseIntegrationTest { + + @Test + public void repro1() { + client.find(Criteria.where().key("foo").operator(Operator.EQUALS) + .value("Foo’s")); + Assert.assertTrue(true); // lack of Exception means test passes + } + + @Test + public void repor2() { + client.find(Criteria.where().key("foo").operator(Operator.EQUALS) + .value("“A and B”")); + Assert.assertTrue(true); // lack of Exception means test passes + } + +} From fc46a73e60d3bc162144595f3248aba67038d17a Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Sat, 16 Feb 2019 21:16:37 -0500 Subject: [PATCH 06/10] add release date --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7dab080f1e..28819f1ff5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,7 +13,7 @@ * Removed the `Strings` utility class in favor of `AnyStrings` from `accent4j`. * Removed the `StringSplitter` framework in favor of the same from `accent4j`. -#### Version 0.9.6 (TBD) +#### Version 0.9.6 (February 16, 2019) * Fixed a bug that caused a `ParseException` to be thrown when trying to use a `Criteria` object containing a string value wrapped in single or double quotes out of necessity (i.e. because the value contained a keyword). This bug happened because the wrapping quotes were dropped by Concourse Server when parsing the `Criteria`. * Fixed a bug where the CCL parser failed to handle some Unicode quote characters. From a4cc5cb8689b309261a74d6b55b5d09a528c33ba Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Mon, 20 May 2019 12:53:32 -0500 Subject: [PATCH 07/10] Improve handling of implicitly built Criteria (#366) * Refactor Criteria to be an interface that applies to all buildable states * Remove driver methods that took a generic Object criteria parameter. These are now unnecessary since the Criteria interface is implemented by BuiildableState * update changelog * fix formatting * Deprecate Criteria#getCclString in favor of Criteria#ccl * make method final * Revert "make method final" This reverts commit 367400ba07f7f31b33f379713bb85b56af8e6a6e. --- CHANGELOG.md | 2 + .../com/cinchapi/concourse/Concourse.java | 435 ------------------ .../concourse/ConcourseThriftDriver.java | 152 ------ .../java/com/cinchapi/concourse/Link.java | 2 +- .../concourse/lang/BuildableStartState.java | 2 +- .../concourse/lang/BuildableState.java | 28 +- .../concourse/lang/BuiltCriteria.java | 165 +++++++ .../com/cinchapi/concourse/lang/Criteria.java | 125 +---- .../com/cinchapi/concourse/lang/KeyState.java | 2 +- .../com/cinchapi/concourse/lang/Language.java | 4 +- .../concourse/lang/OperatorState.java | 2 +- .../cinchapi/concourse/lang/StartState.java | 2 +- .../com/cinchapi/concourse/lang/State.java | 6 +- .../concourse/lang/TimestampState.java | 2 +- .../cinchapi/concourse/lang/ValueState.java | 2 +- .../com/cinchapi/concourse/util/Parsers.java | 10 +- .../cinchapi/concourse/lang/CriteriaTest.java | 8 +- .../server/ManagedConcourseServer.java | 83 ---- .../importer/debug/ImportDryRunConcourse.java | 73 --- .../cinchapi/concourse/FindCriteriaTest.java | 19 +- .../cinchapi/concourse/lang/ParserTest.java | 58 +-- 21 files changed, 268 insertions(+), 914 deletions(-) create mode 100644 concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuiltCriteria.java diff --git a/CHANGELOG.md b/CHANGELOG.md index 28819f1ff5..65f593a648 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,8 @@ * The `Transform` class contains functions for common data transformations. * Removed the `Strings` utility class in favor of `AnyStrings` from `accent4j`. * Removed the `StringSplitter` framework in favor of the same from `accent4j`. +* Refactored the `Criteria` class into an interface that is implemented by any language symbols that can be immediately transformed to a well-built criteria (e.g. `ValueState` and `TimestampState`). The primary benefit of this change is that methods that took a generic Object parameter and checked whether that object could be built into a `Criteria` have now been removed from the `Concourse` driver since that logic is automatically captured within the new class hiearchy. Another positive side effect of this change is that it is no longer necessary to explicitly build a nested `Criteria` when using the `group` functionality of the `Criteria` builder. +* Deprecated `Criteria#getCclString` in favor of `Criteria#ccl`. #### Version 0.9.6 (February 16, 2019) * Fixed a bug that caused a `ParseException` to be thrown when trying to use a `Criteria` object containing a string value wrapped in single or double quotes out of necessity (i.e. because the value contained a keyword). This bug happened because the wrapping quotes were dropped by Concourse Server when parsing the `Criteria`. diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/Concourse.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/Concourse.java index f7ee0309dc..e702336dd2 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/Concourse.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/Concourse.java @@ -827,25 +827,6 @@ public abstract Map>> diff(String key, */ public abstract Set find(Criteria criteria); - /** - * Return the set of records that satisfy the {@code criteria}. - *

- * This method is syntactic sugar for {@link #find(Criteria)}. The only - * difference is that this method takes a in-process {@link Criteria} - * building sequence for convenience. - *

- * - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired records - * @return the records that match the {@code criteria} - */ - public abstract Set find(Object criteria); // this method exists in - // case the caller - // forgets - // to called #build() on - // the CriteriaBuilder - /** * Return the set of records that satisfy the {@code ccl} filter. * @@ -1444,59 +1425,6 @@ public abstract Map get(Collection keys, public abstract Map get(Collection keys, long record, Timestamp timestamp); - /** - * For each of the {@code keys} in every record that matches the - * {@code criteria}, return the stored value that was most recently - * added. - *

- * This method is syntactic sugar for {@link #get(Collection, Criteria)}. - * The only difference is that this method takes a in-process - * {@link Criteria} building sequence for convenience. - *

- * - * @param keys a collection of field names - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the {@code keys} to the freshest - * value in the field - */ - public abstract Map> get(Collection keys, - Object criteria); - - /** - * For each of the {@code keys} in every record that matches the - * {@code criteria}, return the stored value that was most recently - * added at {@code timestamp}. - *

- * This method is syntactic sugar for - * {@link #get(Collection, Criteria, Timestamp)}. The only difference is - * that this method takes a in-process {@link Criteria} building sequence - * for convenience. - *

- * - * @param keys a collection of field names - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the {@code keys} to the freshest - * value in the field at {@code timestamp} - */ - public abstract Map> get(Collection keys, - Object criteria, Timestamp timestamp); - /** * For each of the {@code keys} in every record that matches the {@code ccl} * filter, return the stored value that was most recently added. @@ -1567,43 +1495,6 @@ public abstract Map> get(Collection keys, public abstract Map> get(Criteria criteria, Timestamp timestamp); - /** - * For every key in every record that matches the {@code criteria}, return - * the stored value that was most recently added. - * - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the record's keys to the freshest - * value in the field - */ - public abstract Map> get(Object criteria); - - /** - * For every key in every record that matches the {@code criteria}, return - * the stored value that was most recently added at {@code timestamp}. - * - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the record's keys to the freshest - * value in the field at {@code timestamp} - */ - public abstract Map> get(Object criteria, - Timestamp timestamp); - /** * For every key in every record that matches the {@code ccl} filter, return * the stored value that was most recently added. @@ -1747,55 +1638,6 @@ public final T get(String key, Long record, Timestamp timestamp) { return get(key, record.longValue(), timestamp); } - /** - * For every record that matches the {@code criteria}, return the stored - * value in the {@code key} field that was most recently added. - *

- * This method is syntactic sugar for {@link #get(String, Criteria)}. The - * only difference is that this method takes a in-process {@link Criteria} - * building sequence for convenience. - *

- * - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the record's keys to the freshest - * value in the field - */ - public abstract Map get(String key, Object criteria); - - /** - * For every record that matches the {@code criteria}, return the - * stored value in the {@code key} field that was most recently added at - * {@code timestamp}. - *

- * This method is syntactic sugar for - * {@link #get(String, Criteria, Timestamp)}. The only difference is that - * this method takes a in-process {@link Criteria} building sequence for - * convenience. - *

- * - * @param key the field name - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the matching records to the - * freshest value in the {@code key} field - */ - public abstract Map get(String key, Object criteria, - Timestamp timestamp); - /** * For every record that matches the {@code ccl} filter, return the * stored value in the {@code key} field that was most recently added. @@ -2437,68 +2279,6 @@ public abstract Map>> navigate( public abstract Map>> navigate( Collection keys, long record, Timestamp timestamp); - /** - * Traverse the document-graph along each of the navigation {@code keys}, - * starting at each of the records that match the {@code criteria} and - * return the data contained at each of the destinations. - * - * @param keys a collection of navigation keys - * @param criteria a {@link Criteria} that contains a well-formed filter for - * the desired records - * @return a {@link Map} associating each of the destination {@code records} - * to another {@link Map} associating each of the destination - * {@code keys} to a {@link Set} containing all the values stored in - * the respective fields - * @see https://docs.cinchapi.com/concourse/guide/glossary/#navigation-key - */ - public final Map>> navigate( - Collection keys, Object criteria) { - if(criteria instanceof BuildableState) { - return navigate(keys, ((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the navigate method"); - } - } - - /** - * Traverse the document-graph at {@code timestamp} along each of the - * navigation {@code keys}, starting at each of the records that matched the - * {@code criteria} and return the data contained at each of the - * destinations at {@code timestamp}. - * - * @param keys a collection of navigation keys - * @param criteria a {@link Criteria} that contains a well-formed filter for - * the desired records - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the destination {@code records} - * to another {@link Map} associating each of the destination - * {@code keys} to a {@link Set} containing all the values stored in - * the respective fields at {@code timestamp} - * @see https://docs.cinchapi.com/concourse/guide/glossary/#navigation-key - */ - public final Map>> navigate( - Collection keys, Object criteria, Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return navigate(keys, ((BuildableState) criteria).build(), - timestamp); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the navigate method"); - } - } - /** * Traverse the document-graph along each of the navigation {@code keys}, * starting at each of the records that match the {@code criteria} and @@ -2705,68 +2485,6 @@ public final Map> navigate(String key, Long record, return navigate(key, record.longValue(), timestamp); } - /** - * Return all the values stored for {@code key} in every record that - * matches the {@link Criteria} filter. Navigates through the key splited - * with dot(.) operator. - *

- * Iterates only if the key has a link as value which - * points to another record. - *

- * - * @param key the field name - * @param ccl a well-formed criteria expressed using the Concourse Criteria - * Language - * @return a {@link Map} associating each of the the matching records to a - * {@link Set} containing all the values stored in the respective - * field - */ - public final Map> navigate(String key, Object criteria) { - if(criteria instanceof BuildableState) { - return navigate(key, ((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the navigate method"); - } - } - - /** - * Return all the values stored for {@code key} in every record that - * matches the {@link Criteria} filter. Navigates through the key splited - * with dot(.) operator. - *

- * Iterates only if the key has a link as value which - * points to another record. - *

- * - * @param key the field name - * @param ccl a well-formed criteria expressed using the Concourse Criteria - * Language - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the the matching records to a - * {@link Set} containing all the values stored in the respective - * field - */ - public final Map> navigate(String key, Object criteria, - Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return navigate(key, ((BuildableState) criteria).build(), - timestamp); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the navigate method"); - } - } - /** * Return all the values stored for {@code key} in every record that * matches the {@code ccl} filter. Navigates through the key splited @@ -3113,59 +2831,6 @@ public abstract Map> select(Collection keys, public abstract Map> select(Collection keys, long record, Timestamp timestamp); - /** - * Return all the values stored for each of the {@code keys} in every record - * that matches the {@code criteria}. - *

- * This method is syntactic sugar for {@link #select(Collection, Criteria)}. - * The only difference is that this method takes a in-process - * {@link Criteria} building sequence for convenience. - *

- * - * @param keys a collection of field names - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the {@code keys} in that record - * to a {@link Set} containing all the values stored in the - * respective field - */ - public abstract Map>> select( - Collection keys, Object criteria); - - /** - * Return all the values stored for each of the {@code keys} at - * {@code timestamp} in every record that matches the {@code criteria}. - *

- * This method is syntactic sugar for - * {@link #select(Collection, Criteria, Timestamp)}. The only difference is - * that this method takes a in-process {@link Criteria} building sequence - * for convenience. - *

- * - * @param keys a collection of field names - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the {@code keys} in that record - * to a {@link Set} containing all the values stored in the - * respective field at {@code timestamp} - */ - public abstract Map>> select( - Collection keys, Object criteria, Timestamp timestamp); - /** * Return all the values stored for each of the {@code keys} in every record * that matches the {@code ccl} filter. @@ -3303,56 +2968,6 @@ public final Map> select(Long record, return select(record.longValue(), timestamp); } - /** - * Return all the data from every record that matches {@code criteria}. - *

- * This method is syntactic sugar for {@link #select(Criteria)}. The only - * difference is that this method takes a in-process {@link Criteria} - * building sequence for convenience. - *

- * - * @param keys a collection of field names - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the {@code keys} in that record - * to a {@link Set} containing all the values stored in the - * respective field - */ - public abstract Map>> select(Object criteria); - - /** - * Return all the data at {@code timestamp} from every record that - * matches the {@code criteria}. - *

- * This method is syntactic sugar for {@link #select(Criteria, Timestamp)}. - * The only difference is that this method takes a in-process - * {@link Criteria} building sequence for convenience. - *

- * - * @param keys a collection of field names - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the matching records to another - * {@link Map} associating each of the {@code keys} in that record - * to a {@link Set} containing all the values stored in the - * respective field at {@code timestamp} - */ - public abstract Map>> select(Object criteria, - Timestamp timestamp); - /** * Return all the data from every record that matches {@code ccl} filter. * @@ -3496,56 +3111,6 @@ public final Set select(String key, Long record, return select(key, record.longValue(), timestamp); } - /** - * Return all the values stored for {@code key} in every record that - * matches the {@code criteria}. - *

- * This method is syntactic sugar for {@link #select(String, Criteria)}. The - * only difference is that this method takes a in-process {@link Criteria} - * building sequence for convenience. - *

- * - * @param key the field name - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @return a {@link Map} associating each of the matching records to a - * {@link Set} containing all the values stored in the respective - * field - */ - public abstract Map> select(String key, Object criteria); - - /** - * Return all the values stored for {@code key} at {@code timestamp} in - * every record that matches the {@code criteria}. - *

- * This method is syntactic sugar for - * {@link #select(String, Criteria, Timestamp)}. The only difference is that - * this method takes a in-process {@link Criteria} building sequence for - * convenience. - *

- * - * @param key the field name - * @param criteria an in-process {@link Criteria} building sequence that - * contains an {@link BuildableState#build() unfinalized}, - * but well-formed filter for the desired - * records - * @param timestamp a {@link Timestamp} that represents the historical - * instant to use in the lookup – created from either a - * {@link Timestamp#fromString(String) natural language - * description} of a point in time (i.e. two weeks ago), OR - * the {@link Timestamp#fromMicros(long) number - * of microseconds} since the Unix epoch, OR - * a {@link Timestamp#fromJoda(org.joda.time.DateTime) Joda - * DateTime} object - * @return a {@link Map} associating each of the matching records to a - * {@link Set} containing all the values stored in the respective - * field at {@code timestamp} - */ - public abstract Map> select(String key, Object criteria, - Timestamp timestamp); - /** * Return all the values stored for {@code key} in every record that * matches the {@code ccl} filter. diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/ConcourseThriftDriver.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/ConcourseThriftDriver.java index a500bcf3e2..dee609f25a 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/ConcourseThriftDriver.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/ConcourseThriftDriver.java @@ -36,7 +36,6 @@ import com.cinchapi.common.base.CheckedExceptions; import com.cinchapi.concourse.config.ConcourseClientPreferences; -import com.cinchapi.concourse.lang.BuildableState; import com.cinchapi.concourse.lang.Criteria; import com.cinchapi.concourse.lang.Language; import com.cinchapi.concourse.security.ClientSecurity; @@ -830,17 +829,6 @@ public Set find(Criteria criteria) { }); } - @Override - public Set find(Object criteria) { - if(criteria instanceof BuildableState) { - return find(((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the find method"); - } - } - @Override public Set find(String ccl) { return execute(() -> { @@ -1063,30 +1051,6 @@ public Map get(Collection keys, long record, }); } - @Override - public Map> get(Collection keys, - Object criteria) { - if(criteria instanceof BuildableState) { - return get(keys, ((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - - @Override - public Map> get(Collection keys, - Object criteria, Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return get(keys, ((BuildableState) criteria).build(), timestamp); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - @Override public Map> get(Collection keys, String ccl) { @@ -1172,29 +1136,6 @@ public Map> get(Criteria criteria, }); } - @Override - public Map> get(Object criteria) { - if(criteria instanceof BuildableState) { - return get(((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - - @Override - public Map> get(Object criteria, - Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return get(((BuildableState) criteria).build(), timestamp); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - @Override public Map> get(String ccl) { return execute(() -> { @@ -1324,29 +1265,6 @@ public T get(String key, long record, Timestamp timestamp) { }); } - @Override - public Map get(String key, Object criteria) { - if(criteria instanceof BuildableState) { - return get(key, ((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - - @Override - public Map get(String key, Object criteria, - Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return get(key, ((BuildableState) criteria).build(), timestamp); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - @SuppressWarnings("unchecked") @Override public Map get(String key, String ccl) { @@ -2112,30 +2030,6 @@ public Map> select(Collection keys, long record, }); } - @Override - public Map>> select(Collection keys, - Object criteria) { - if(criteria instanceof BuildableState) { - return select(keys, ((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the select method"); - } - } - - @Override - public Map>> select(Collection keys, - Object criteria, Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return select(keys, ((BuildableState) criteria).build(), timestamp); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the select method"); - } - } - @Override public Map>> select(Collection keys, String ccl) { @@ -2266,29 +2160,6 @@ public Map> select(long record, Timestamp timestamp) { }); } - @Override - public Map>> select(Object criteria) { - if(criteria instanceof BuildableState) { - return select(((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - - @Override - public Map>> select(Object criteria, - Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return select(((BuildableState) criteria).build(), timestamp); - } - else { - throw new IllegalArgumentException( - criteria + " is not a valid argument for the get method"); - } - } - @Override public Map>> select(String ccl) { return execute(() -> { @@ -2420,29 +2291,6 @@ public Set select(String key, long record, Timestamp timestamp) { }); } - @Override - public Map> select(String key, Object criteria) { - if(criteria instanceof BuildableState) { - return select(key, ((BuildableState) criteria).build()); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the select method"); - } - } - - @Override - public Map> select(String key, Object criteria, - Timestamp timestamp) { - if(criteria instanceof BuildableState) { - return select(key, ((BuildableState) criteria).build(), timestamp); - } - else { - throw new IllegalArgumentException(criteria - + " is not a valid argument for the select method"); - } - } - @Override public Map> select(String key, String ccl) { return execute(() -> { diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java index 3bdf08261e..52f87280b7 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/Link.java @@ -118,7 +118,7 @@ public static String toWhere(String ccl) { * resolvable link instruction} */ public static String toWhere(Criteria criteria) { - return toWhere(criteria.getCclString()); + return toWhere(criteria.ccl()); } /** diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableStartState.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableStartState.java index 9e8fa903a9..7351441efc 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableStartState.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableStartState.java @@ -30,7 +30,7 @@ public class BuildableStartState extends BuildableState { * * @param criteria */ - protected BuildableStartState(Criteria criteria) { + protected BuildableStartState(BuiltCriteria criteria) { super(criteria); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableState.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableState.java index b1d06f0d84..515849a6ee 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableState.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuildableState.java @@ -15,7 +15,11 @@ */ package com.cinchapi.concourse.lang; +import java.util.List; + import com.cinchapi.ccl.grammar.ConjunctionSymbol; +import com.cinchapi.ccl.grammar.Symbol; +import com.cinchapi.concourse.Timestamp; /** * The base class for a language state that can be transformed into a complete @@ -23,14 +27,14 @@ * * @author Jeff Nelson */ -public abstract class BuildableState extends State { +public abstract class BuildableState extends State implements Criteria { /** * Construct a new instance. * * @param criteria */ - protected BuildableState(Criteria criteria) { + protected BuildableState(BuiltCriteria criteria) { super(criteria); } @@ -64,4 +68,24 @@ public StartState or() { return new StartState(criteria); } + @Override + public Criteria at(Timestamp timestamp) { + return build().at(timestamp); + } + + @Override + public final String ccl() { + return build().ccl(); + } + + @Override + public final List symbols() { + return build().symbols(); + } + + @Override + public final String toString() { + return build().toString(); + } + } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuiltCriteria.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuiltCriteria.java new file mode 100644 index 0000000000..8760b660e6 --- /dev/null +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/BuiltCriteria.java @@ -0,0 +1,165 @@ +/* + * Copyright (c) 2013-2019 Cinchapi Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.cinchapi.concourse.lang; + +import java.util.Collections; +import java.util.List; +import java.util.Objects; + +import com.cinchapi.ccl.Parser; +import com.cinchapi.ccl.Parsing; +import com.cinchapi.ccl.grammar.Expression; +import com.cinchapi.ccl.grammar.ParenthesisSymbol; +import com.cinchapi.ccl.grammar.Symbol; +import com.cinchapi.ccl.grammar.TimestampSymbol; +import com.cinchapi.common.reflect.Reflection; +import com.cinchapi.concourse.Timestamp; +import com.cinchapi.concourse.util.Parsers; +import com.google.common.base.Preconditions; +import com.google.common.collect.Lists; + +/** + * A {@link Criteria} that has been {@link BuildableState#build()}. + * + * @author Jeff Nelson + */ +public class BuiltCriteria implements Criteria { + + /** + * A flag that indicates whether this {@link Criteria} has been built. + */ + private boolean built = false; + + /** + * The collection of {@link Symbol}s that make up this {@link Criteria}. + */ + List symbols; + + /** + * Construct a new instance. + */ + protected BuiltCriteria() { + this.symbols = Lists.newArrayList(); + } + + /** + * Return this {@link Criteria} with each expression (e.g. {key} {operator} + * {values}) pinned to the specified {@code timestamp}. + * + * NOTE: Any timestamps that are pinned to any expressions + * within this Criteria will be replaced by the specified {@code timestamp}. + * + * @param timestamp the {@link Timestamp} to which the returned + * {@link Criteria} is pinned + * + * @return this {@link Criteria} pinned to {@code timestamp} + */ + public Criteria at(Timestamp timestamp) { + Parser parser = Parsers.create(ccl()); + List symbols = Parsing.groupExpressions(parser.tokenize()); + TimestampSymbol ts = new TimestampSymbol(timestamp.getMicros()); + symbols.forEach((symbol) -> { + if(symbol instanceof Expression) { + Expression expression = (Expression) symbol; + Reflection.set("timestamp", ts, expression); // (authorized) + } + }); + BuiltCriteria criteria = new BuiltCriteria(); + symbols = Parsing.ungroupExpressions(symbols); + criteria.symbols = symbols; + return criteria; + } + + @Override + public String ccl() { + StringBuilder sb = new StringBuilder(); + boolean first = true; + for (Symbol symbol : symbols) { + if(!first) { + sb.append(" "); + } + sb.append(symbol); + first = false; + } + return sb.toString(); + } + + @Override + public boolean equals(Object obj) { + if(obj instanceof Criteria) { + return Objects.equals(symbols, ((Criteria) obj).symbols()); + } + else { + return false; + } + } + + @Override + public int hashCode() { + return Objects.hash(symbols); + } + + @Override + public List symbols() { + return Collections.unmodifiableList(symbols); + } + + @Override + public String toString() { + return ccl(); + } + + /** + * Expand any sub/grouped Criteria. + * + * @param symbols + * @param expanded + */ + private void expand(List symbols, List expanded) { + for (Symbol symbol : symbols) { + if(symbol instanceof Criteria) { + expanded.add(ParenthesisSymbol.LEFT); + expand(((Criteria) symbol).symbols(), expanded); + expanded.add(ParenthesisSymbol.RIGHT); + } + else { + expanded.add(symbol); + } + } + } + + /** + * Add a {@link Symbol} to this {@link Criteria}. + * + * @param symbol + */ + protected void add(Symbol symbol) { + Preconditions.checkState(!built, + "Cannot add a symbol to a built Criteria"); + symbols.add(symbol); + } + + /** + * Mark this {@link Criteria} as {@code built}. + */ + protected void close() { + built = !built ? true : built; + List expanded = Lists.newArrayList(); + expand(symbols, expanded); + this.symbols = expanded; + } + +} diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Criteria.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Criteria.java index 00123ab67a..028e5237f4 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Criteria.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Criteria.java @@ -15,23 +15,15 @@ */ package com.cinchapi.concourse.lang; -import java.util.Collections; import java.util.List; -import java.util.Objects; import com.cinchapi.ccl.Parser; -import com.cinchapi.ccl.Parsing; import com.cinchapi.ccl.SyntaxException; -import com.cinchapi.ccl.grammar.Expression; -import com.cinchapi.ccl.grammar.ParenthesisSymbol; import com.cinchapi.ccl.grammar.Symbol; -import com.cinchapi.ccl.grammar.TimestampSymbol; import com.cinchapi.common.base.CheckedExceptions; -import com.cinchapi.common.reflect.Reflection; import com.cinchapi.concourse.ParseException; import com.cinchapi.concourse.Timestamp; import com.cinchapi.concourse.util.Parsers; -import com.google.common.base.Preconditions; import com.google.common.collect.Lists; /** @@ -50,7 +42,7 @@ * * @author Jeff Nelson */ -public class Criteria implements Symbol { +public interface Criteria extends Symbol { /** * Return a {@link Criteria} object that expresses the same as the @@ -61,7 +53,7 @@ public class Criteria implements Symbol { */ public static Criteria parse(String ccl) { Parser parser = Parsers.create(ccl); - Criteria criteria = new Criteria(); + BuiltCriteria criteria = new BuiltCriteria(); try { criteria.symbols = Lists.newArrayList(parser.tokenize()); return criteria; @@ -87,24 +79,7 @@ public static Criteria parse(String ccl) { * @return the Criteria builder */ public static StartState where() { - return new StartState(new Criteria()); - } - - /** - * A flag that indicates whether this {@link Criteria} has been built. - */ - private boolean built = false; - - /** - * The collection of {@link Symbol}s that make up this {@link Criteria}. - */ - private List symbols; - - /** - * Construct a new instance. - */ - protected Criteria() { - this.symbols = Lists.newArrayList(); + return new StartState(new BuiltCriteria()); } /** @@ -119,79 +94,24 @@ protected Criteria() { * * @return this {@link Criteria} pinned to {@code timestamp} */ - public Criteria at(Timestamp timestamp) { - Parser parser = Parsers.create(getCclString()); - List symbols = Parsing.groupExpressions(parser.tokenize()); - TimestampSymbol ts = new TimestampSymbol(timestamp.getMicros()); - symbols.forEach((symbol) -> { - if(symbol instanceof Expression) { - Expression expression = (Expression) symbol; - Reflection.set("timestamp", ts, expression); // (authorized) - } - }); - Criteria criteria = new Criteria(); - symbols = Parsing.ungroupExpressions(symbols); - criteria.symbols = symbols; - return criteria; - } - - @Override - public boolean equals(Object obj) { - if(obj instanceof Criteria) { - return Objects.equals(symbols, ((Criteria) obj).symbols); - } - else { - return false; - } - } + public Criteria at(Timestamp timestamp); /** * Return a CCL string that is equivalent to this object. * * @return an equivalent CCL string */ - public String getCclString() { - StringBuilder sb = new StringBuilder(); - boolean first = true; - for (Symbol symbol : symbols) { - if(!first) { - sb.append(" "); - } - sb.append(symbol); - first = false; - } - return sb.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(symbols); - } - - @Override - public String toString() { - return getCclString(); - } + public String ccl(); /** - * Add a {@link Symbol} to this {@link Criteria}. + * Return a CCL string that is equivalent to this object. * - * @param symbol - */ - protected void add(Symbol symbol) { - Preconditions.checkState(!built, - "Cannot add a symbol to a built Criteria"); - symbols.add(symbol); - } - - /** - * Mark this {@link Criteria} as {@code built}. + * @return an equivalent CCL string + * @deprecated in favor of {@link #ccl()} */ - protected void close() { - built = !built ? true : built; - List expanded = Lists.newArrayList(); - expand(symbols, expanded); - this.symbols = expanded; + @Deprecated + public default String getCclString() { + return ccl(); } /** @@ -199,27 +119,6 @@ protected void close() { * * @return symbols */ - protected List getSymbols() { - return Collections.unmodifiableList(symbols); - } - - /** - * Expand any sub/grouped Criteria. - * - * @param symbols - * @param expanded - */ - private void expand(List symbols, List expanded) { - for (Symbol symbol : symbols) { - if(symbol instanceof Criteria) { - expanded.add(ParenthesisSymbol.LEFT); - expand(((Criteria) symbol).symbols, expanded); - expanded.add(ParenthesisSymbol.RIGHT); - } - else { - expanded.add(symbol); - } - } - } + public List symbols(); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/KeyState.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/KeyState.java index a7a4fc70d1..c3492d27b4 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/KeyState.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/KeyState.java @@ -31,7 +31,7 @@ public class KeyState extends State { * * @param criteria */ - protected KeyState(Criteria criteria) { + protected KeyState(BuiltCriteria criteria) { super(criteria); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java index 34269c2ad0..54b6ede121 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/Language.java @@ -103,7 +103,7 @@ else if(tsymbol.getType() == TSymbolType.TIMESTAMP) { */ public static TCriteria translateToThriftCriteria(Criteria criteria) { List symbols = Lists.newArrayList(); - for (Symbol symbol : criteria.getSymbols()) { + for (Symbol symbol : criteria.symbols()) { symbols.add(translateToThriftSymbol(symbol)); } return new TCriteria(symbols); @@ -116,7 +116,7 @@ public static TCriteria translateToThriftCriteria(Criteria criteria) { * @return the analogous Java {@link Criteria} */ public static Criteria translateFromThriftCriteria(TCriteria tcriteria) { - Criteria criteria = new Criteria(); + BuiltCriteria criteria = new BuiltCriteria(); for (TSymbol tsymbol : tcriteria.getSymbols()) { criteria.add(translateFromThriftSymbol(tsymbol)); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/OperatorState.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/OperatorState.java index 1036d61f34..2bee4274c8 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/OperatorState.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/OperatorState.java @@ -29,7 +29,7 @@ public class OperatorState extends State { * * @param criteria */ - protected OperatorState(Criteria criteria) { + protected OperatorState(BuiltCriteria criteria) { super(criteria); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/StartState.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/StartState.java index 848afae075..6b996e52b0 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/StartState.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/StartState.java @@ -29,7 +29,7 @@ public class StartState extends State { * * @param criteria */ - public StartState(Criteria criteria) { + public StartState(BuiltCriteria criteria) { super(criteria); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/State.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/State.java index e867ab5f88..ab5cb17be4 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/State.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/State.java @@ -30,16 +30,16 @@ public abstract class State { /** - * A reference to the {@link Criteria} that is being built. + * A reference to the {@link BuiltCriteria} that is being built. */ - protected final Criteria criteria; + protected final BuiltCriteria criteria; /** * Construct a new instance. * * @param criteria */ - protected State(Criteria criteria) { + protected State(BuiltCriteria criteria) { this.criteria = criteria; } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/TimestampState.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/TimestampState.java index 193e52bbac..c6db8aa777 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/TimestampState.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/TimestampState.java @@ -28,7 +28,7 @@ public class TimestampState extends BuildableState { * * @param criteria */ - protected TimestampState(Criteria criteria) { + protected TimestampState(BuiltCriteria criteria) { super(criteria); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/ValueState.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/ValueState.java index c86d8ceb58..fc871d6b46 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/ValueState.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/lang/ValueState.java @@ -32,7 +32,7 @@ public class ValueState extends BuildableState { * * @param criteria */ - protected ValueState(Criteria criteria) { + protected ValueState(BuiltCriteria criteria) { super(criteria); } diff --git a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Parsers.java b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Parsers.java index df2ab84b37..11f331b7cd 100644 --- a/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Parsers.java +++ b/concourse-driver-java/src/main/java/com/cinchapi/concourse/util/Parsers.java @@ -36,7 +36,7 @@ public final class Parsers { * @return a {@link Parser} */ public static Parser create(Criteria criteria) { - return create(criteria.getCclString()); + return create(criteria.ccl()); } /** @@ -49,7 +49,7 @@ public static Parser create(Criteria criteria) { */ public static Parser create(Criteria criteria, Multimap data) { - return create(criteria.getCclString(), data); + return create(criteria.ccl(), data); } /** @@ -83,8 +83,7 @@ public static Parser create(String ccl, Multimap data) { * @return a {@link Parser} */ public static Parser create(TCriteria criteria) { - return create( - Language.translateFromThriftCriteria(criteria).getCclString()); + return create(Language.translateFromThriftCriteria(criteria).ccl()); } /** @@ -97,8 +96,7 @@ public static Parser create(TCriteria criteria) { */ public static Parser create(TCriteria criteria, Multimap data) { - return create( - Language.translateFromThriftCriteria(criteria).getCclString(), + return create(Language.translateFromThriftCriteria(criteria).ccl(), data); } diff --git a/concourse-driver-java/src/test/java/com/cinchapi/concourse/lang/CriteriaTest.java b/concourse-driver-java/src/test/java/com/cinchapi/concourse/lang/CriteriaTest.java index a8b06e4746..cfcc49bd76 100644 --- a/concourse-driver-java/src/test/java/com/cinchapi/concourse/lang/CriteriaTest.java +++ b/concourse-driver-java/src/test/java/com/cinchapi/concourse/lang/CriteriaTest.java @@ -42,7 +42,7 @@ public class CriteriaTest { public void testCannotAddSymbolToBuiltCriteria() { Criteria criteria = Criteria.where().key("foo") .operator(Operator.EQUALS).value("bar").build(); - criteria.add(new KeySymbol("baz")); + ((BuiltCriteria) criteria).add(new KeySymbol("baz")); } @Test @@ -65,7 +65,7 @@ public void testTimestampPinning() { .build(); Timestamp timestamp = Timestamp.now(); criteria = criteria.at(timestamp); - List symbols = Parsing.groupExpressions(criteria.getSymbols()); + List symbols = Parsing.groupExpressions(criteria.symbols()); symbols.forEach((symbol) -> { if(symbol instanceof Expression) { Expression expression = (Expression) symbol; @@ -86,7 +86,7 @@ public void testTimestampPinningSomeTimestamps() { .build(); Timestamp timestamp = Timestamp.now(); criteria = criteria.at(timestamp); - List symbols = Parsing.groupExpressions(criteria.getSymbols()); + List symbols = Parsing.groupExpressions(criteria.symbols()); symbols.forEach((symbol) -> { if(symbol instanceof Expression) { Expression expression = (Expression) symbol; @@ -101,7 +101,7 @@ public void testParseCcl() { String ccl = "name = jeff AND (company = Cinchapi at 12345 or company = Blavity)"; Criteria criteria = Criteria.parse(ccl); Parser parser1 = Parsers.create(ccl); - Parser parser2 = Parsers.create(criteria.getCclString()); + Parser parser2 = Parsers.create(criteria.ccl()); Assert.assertEquals(Parsing.groupExpressions(parser1.tokenize()), Parsing.groupExpressions(parser2.tokenize())); } diff --git a/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java b/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java index 4ea893bb79..bad10a7c18 100644 --- a/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java +++ b/concourse-ete-test-core/src/main/java/com/cinchapi/concourse/server/ManagedConcourseServer.java @@ -1211,11 +1211,6 @@ public Set find(Criteria criteria) { return invoke("find", Criteria.class).with(criteria); } - @Override - public Set find(Object criteria) { - return invoke("find", Object.class).with(criteria); - } - @Override public Set find(String ccl) { return invoke("find", String.class).with(ccl); @@ -1349,20 +1344,6 @@ public Map get(Collection keys, long record, .with(keys, record, timestamp); } - @Override - public Map> get(Collection keys, - Object criteria) { - return invoke("get", Collection.class, Object.class).with(keys, - criteria); - } - - @Override - public Map> get(Collection keys, - Object criteria, Timestamp timestamp) { - return invoke("get", Collection.class, Object.class, - Timestamp.class).with(keys, criteria, timestamp); - } - @Override public Map> get(Collection keys, String ccl) { @@ -1389,18 +1370,6 @@ public Map> get(Criteria criteria, timestamp); } - @Override - public Map> get(Object criteria) { - return invoke("get", Object.class).with(criteria); - } - - @Override - public Map> get(Object criteria, - Timestamp timestamp) { - return invoke("get", Object.class, Timestamp.class).with(criteria, - timestamp); - } - @Override public Map> get(String ccl) { return invoke("get", String.class).with(ccl); @@ -1443,19 +1412,6 @@ public T get(String key, long record, Timestamp timestamp) { .with(key, record, timestamp); } - @Override - public Map get(String key, Object criteria) { - return invoke("get", String.class, Object.class).with(key, - criteria); - } - - @Override - public Map get(String key, Object criteria, - Timestamp timestamp) { - return invoke("get", String.class, Object.class, Timestamp.class) - .with(key, criteria, timestamp); - } - @Override public Map get(String key, String ccl) { return invoke("get", String.class, String.class).with(key, ccl); @@ -1816,20 +1772,6 @@ public Map> select(Collection keys, Timestamp.class).with(keys, record, timestamp); } - @Override - public Map>> select( - Collection keys, Object criteria) { - return invoke("select", Collection.class, Object.class).with(keys, - criteria); - } - - @Override - public Map>> select( - Collection keys, Object criteria, Timestamp timestamp) { - return invoke("select", Collection.class, Object.class, - Timestamp.class).with(keys, criteria, timestamp); - } - @Override public Map>> select( Collection keys, String ccl) { @@ -1868,18 +1810,6 @@ public Map> select(long record, timestamp); } - @Override - public Map>> select(Object criteria) { - return invoke("select", Object.class).with(criteria); - } - - @Override - public Map>> select(Object criteria, - Timestamp timestamp) { - return invoke("select", Object.class, Timestamp.class) - .with(criteria, timestamp); - } - @Override public Map>> select(String ccl) { return invoke("select", String.class).with(ccl); @@ -1923,19 +1853,6 @@ public Set select(String key, long record, Timestamp timestamp) { .with(key, record, timestamp); } - @Override - public Map> select(String key, Object criteria) { - return invoke("select", String.class, Object.class).with(key, - criteria); - } - - @Override - public Map> select(String key, Object criteria, - Timestamp timestamp) { - return invoke("select", String.class, Object.class, Timestamp.class) - .with(key, criteria, timestamp); - } - @Override public Map> select(String key, String ccl) { return invoke("select", String.class, String.class).with(key, ccl); diff --git a/concourse-import/src/main/java/com/cinchapi/concourse/importer/debug/ImportDryRunConcourse.java b/concourse-import/src/main/java/com/cinchapi/concourse/importer/debug/ImportDryRunConcourse.java index 445c9f199a..3a820dbe58 100644 --- a/concourse-import/src/main/java/com/cinchapi/concourse/importer/debug/ImportDryRunConcourse.java +++ b/concourse-import/src/main/java/com/cinchapi/concourse/importer/debug/ImportDryRunConcourse.java @@ -304,11 +304,6 @@ public Set find(Criteria criteria) { throw new UnsupportedOperationException(); } - @Override - public Set find(Object criteria) { - throw new UnsupportedOperationException(); - } - @Override public Set find(String ccl) { throw new UnsupportedOperationException(); @@ -423,18 +418,6 @@ public Map get(Collection keys, long record, throw new UnsupportedOperationException(); } - @Override - public Map> get(Collection keys, - Object criteria) { - throw new UnsupportedOperationException(); - } - - @Override - public Map> get(Collection keys, - Object criteria, Timestamp timestamp) { - throw new UnsupportedOperationException(); - } - @Override public Map> get(Collection keys, String ccl) { @@ -458,17 +441,6 @@ public Map> get(Criteria criteria, throw new UnsupportedOperationException(); } - @Override - public Map> get(Object criteria) { - throw new UnsupportedOperationException(); - } - - @Override - public Map> get(Object criteria, - Timestamp timestamp) { - throw new UnsupportedOperationException(); - } - @Override public Map> get(String ccl) { throw new UnsupportedOperationException(); @@ -506,17 +478,6 @@ public T get(String key, long record, Timestamp timestamp) { throw new UnsupportedOperationException(); } - @Override - public Map get(String key, Object criteria) { - throw new UnsupportedOperationException(); - } - - @Override - public Map get(String key, Object criteria, - Timestamp timestamp) { - throw new UnsupportedOperationException(); - } - @Override public Map get(String key, String ccl) { throw new UnsupportedOperationException(); @@ -826,18 +787,6 @@ public Map> select(Collection keys, long record, throw new UnsupportedOperationException(); } - @Override - public Map>> select(Collection keys, - Object criteria) { - throw new UnsupportedOperationException(); - } - - @Override - public Map>> select(Collection keys, - Object criteria, Timestamp timestamp) { - throw new UnsupportedOperationException(); - } - @Override public Map>> select(Collection keys, String ccl) { @@ -871,17 +820,6 @@ public Map> select(long record, Timestamp timestamp) { throw new UnsupportedOperationException(); } - @Override - public Map>> select(Object criteria) { - throw new UnsupportedOperationException(); - } - - @Override - public Map>> select(Object criteria, - Timestamp timestamp) { - throw new UnsupportedOperationException(); - } - @Override public Map>> select(String ccl) { throw new UnsupportedOperationException(); @@ -919,17 +857,6 @@ public Set select(String key, long record, Timestamp timestamp) { throw new UnsupportedOperationException(); } - @Override - public Map> select(String key, Object criteria) { - throw new UnsupportedOperationException(); - } - - @Override - public Map> select(String key, Object criteria, - Timestamp timestamp) { - throw new UnsupportedOperationException(); - } - @Override public Map> select(String key, String ccl) { throw new UnsupportedOperationException(); diff --git a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/FindCriteriaTest.java b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/FindCriteriaTest.java index e29b3ea7e8..41d0275839 100644 --- a/concourse-integration-tests/src/test/java/com/cinchapi/concourse/FindCriteriaTest.java +++ b/concourse-integration-tests/src/test/java/com/cinchapi/concourse/FindCriteriaTest.java @@ -90,11 +90,6 @@ public void testBuildableStateParamSucceeds() { .operator(Operator.GREATER_THAN).value(90).build())); } - @Test(expected = IllegalArgumentException.class) - public void testNonBuildableStateParamDoesNotSucceed() { - client.find(new Object()); - } - @Test public void testSimple() { Assert.assertTrue(hasSameResults(Criteria.where().key("graduation_rate") @@ -197,6 +192,20 @@ public void testReproCON_634() { Assert.assertTrue(true); // lack of Exception means test passes } + @Test + public void testFindCriteriaImplicitBuild() { + Assert.assertTrue(hasSameResults(Criteria.where() + .group(Criteria.where().key("graduation_rate") + .operator(Operator.GREATER_THAN).value(90).or() + .key("yield_men").operator(Operator.EQUALS).value(20)) + .and() + .group(Criteria.where().key("percent_undergrad_black") + .operator(Operator.GREATER_THAN_OR_EQUALS).value(5).or() + .key("total_cost_out_state") + .operator(Operator.GREATER_THAN).value(50000) + .build()))); + } + /** * Validate that the {@code criteria} returns the same result in Concourse * as it does in a relational database. diff --git a/concourse-server/src/test/java/com/cinchapi/concourse/lang/ParserTest.java b/concourse-server/src/test/java/com/cinchapi/concourse/lang/ParserTest.java index 759d3295f4..ae763f60f2 100644 --- a/concourse-server/src/test/java/com/cinchapi/concourse/lang/ParserTest.java +++ b/concourse-server/src/test/java/com/cinchapi/concourse/lang/ParserTest.java @@ -56,7 +56,7 @@ public void testGroupSingle() { Object value = TestData.getObject(); Criteria criteria = Criteria.where().key(key).operator(operator) .value(value).build(); - List symbols = Parsing.groupExpressions(criteria.getSymbols()); + List symbols = Parsing.groupExpressions(criteria.symbols()); Expression exp = (Expression) symbols.get(0); Assert.assertEquals(1, symbols.size()); Assert.assertEquals(exp.raw().key(), key); @@ -75,7 +75,7 @@ public void testGroupAnd() { Criteria criteria = Criteria.where().key(key0).operator(operator0) .value(value0).and().key(key1).operator(operator1).value(value1) .build(); - List symbols = Parsing.groupExpressions(criteria.getSymbols()); + List symbols = Parsing.groupExpressions(criteria.symbols()); Expression exp0 = (Expression) symbols.get(0); ConjunctionSymbol sym = (ConjunctionSymbol) symbols.get(1); Expression exp1 = (Expression) symbols.get(2); @@ -100,7 +100,7 @@ public void testGroupOr() { Criteria criteria = Criteria.where().key(key0).operator(operator0) .value(value0).or().key(key1).operator(operator1).value(value1) .build(); - List symbols = Parsing.groupExpressions(criteria.getSymbols()); + List symbols = Parsing.groupExpressions(criteria.symbols()); Expression exp0 = (Expression) symbols.get(0); ConjunctionSymbol sym = (ConjunctionSymbol) symbols.get(1); Expression exp1 = (Expression) symbols.get(2); @@ -138,7 +138,7 @@ public void testGroupSub() { .value(value1).or().key(key2).operator(operator2) .value(value2).build()) .build(); - List symbols = Parsing.groupExpressions(criteria.getSymbols()); + List symbols = Parsing.groupExpressions(criteria.symbols()); Expression exp0 = (Expression) symbols.get(0); ConjunctionSymbol sym1 = (ConjunctionSymbol) symbols.get(1); ParenthesisSymbol sym2 = (ParenthesisSymbol) symbols.get(2); @@ -170,7 +170,7 @@ public void testGroupSingleBetween() { Object value1 = TestData.getObject(); Criteria criteria = Criteria.where().key(key).operator(operator) .value(value).value(value1).build(); - List symbols = Parsing.groupExpressions(criteria.getSymbols()); + List symbols = Parsing.groupExpressions(criteria.symbols()); Expression exp = (Expression) symbols.get(0); Assert.assertEquals(1, symbols.size()); Assert.assertEquals(exp.raw().key(), key); @@ -184,7 +184,7 @@ public void testToPostfixNotationSimple() { Criteria criteria = Criteria.where().key("foo") .operator(Operator.EQUALS).value("bar").build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(pfn.size(), 1); Assert.assertEquals(((Expression) Iterables.getOnlyElement(pfn)).key(), new KeySymbol("foo")); @@ -202,7 +202,7 @@ public void testParseCclSimple() { .operator(Operator.EQUALS).value("bar").build(); String ccl = "where foo = bar"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -212,7 +212,7 @@ public void testToPostfixNotationSimpleBetween() { Criteria criteria = Criteria.where().key("foo") .operator(Operator.BETWEEN).value("bar").value("baz").build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(pfn.size(), 1); Assert.assertEquals(((Expression) Iterables.getOnlyElement(pfn)).key(), new KeySymbol("foo")); @@ -234,10 +234,10 @@ public void testParseCclBetween() { String ccl = "where foo bw bar baz"; String ccl2 = "where foo >< bar baz"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); Parser parser2 = Parsers.create(ccl2); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser2.order()); } @@ -247,7 +247,7 @@ public void testToPostfixNotationSimpleAnd() { .value(1).and().key("b").operator(Operator.EQUALS).value(2) .build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(pfn.size(), 3); Assert.assertEquals(((Expression) Iterables.get(pfn, 0)), new Expression(new KeySymbol("a"), @@ -267,7 +267,7 @@ public void testParseCclSimpleAnd() { .build(); String ccl = "a = 1 and b = 2"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -277,7 +277,7 @@ public void testToPostfixNotationSimpleOr() { .value(1).or().key("b").operator(Operator.EQUALS).value(2) .build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(pfn.size(), 3); Assert.assertEquals(((Expression) Iterables.get(pfn, 0)), new Expression(new KeySymbol("a"), @@ -297,7 +297,7 @@ public void testParseCclSimpleOr() { .build(); String ccl = "a = 1 or b = 2"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -307,7 +307,7 @@ public void testToPostfixNotationAndOr() { .value(1).and().key("b").operator(Operator.EQUALS).value(2).or() .key("c").operator(Operator.EQUALS).value(3).build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(pfn.size(), 5); Assert.assertEquals(((Expression) Iterables.get(pfn, 0)), new Expression(new KeySymbol("a"), @@ -332,7 +332,7 @@ public void testParseCclAndOr() { .or().key("c").operator(Operator.EQUALS).value(3).build(); String ccl = "a = '1' and b = 2 or c = 3"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -345,7 +345,7 @@ public void testToPostfixNotationAndGroupOr() { .value(3).build()) .build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(((Expression) Iterables.get(pfn, 0)), new Expression(new KeySymbol("a"), new OperatorSymbol(Operator.EQUALS), @@ -373,7 +373,7 @@ public void testPostfixNotationAndGroupOr() { .build(); String ccl = "a = 1 and (b = 2 or c = 3)"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -389,7 +389,7 @@ public void testToPostfixNotationGroupOrAndGroupOr() { .value(4).build()) .build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(((Expression) Iterables.get(pfn, 0)), new Expression(new KeySymbol("a"), new OperatorSymbol(Operator.EQUALS), @@ -425,7 +425,7 @@ public void testParseCclGroupOrAndGroupOr() { .build(); String ccl = "(a = 1 or b = 2) AND (c = 3 or d = 4)"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -442,7 +442,7 @@ public void testParseCclGroupOrAndGroupOrConjuctions() { .build(); String ccl = "(a = 1 || b = 2) && (c = 3 || d = 4)"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -460,7 +460,7 @@ public void testParseCclGroupOrAndGroupOrConjuctionsWithSingleAmpersand() { .build(); String ccl = "(a = 1 || b = 2) & (c = 3 || d = 4)"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -476,7 +476,7 @@ public void testToPostfixNotationGroupOrOrGroupOr() { .value(4).build()) .build(); Queue pfn = Parsing - .toPostfixNotation(criteria.getSymbols()); + .toPostfixNotation(criteria.symbols()); Assert.assertEquals(((Expression) Iterables.get(pfn, 0)), new Expression(new KeySymbol("a"), new OperatorSymbol(Operator.EQUALS), @@ -512,7 +512,7 @@ public void testParseCclGroupOrOrGroupOr() { .build(); String ccl = "(a = 1 or b = 2) or (c = 3 or d = 4)"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -529,7 +529,7 @@ public void testParseCclGroupOrOrConjuction() { .build(); String ccl = "(a = 1 || b = 2) || (c = 3 || d = 4)"; Parser parser = Parsers.create(ccl); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -651,7 +651,7 @@ public void testParseCclLocalReferences() { data.put("age", 30); data.put("team", "Cleveland Cavaliers"); Parser parser = Parsers.create(ccl, data); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -688,7 +688,7 @@ public void testParseCclBetweenWithBothReferences() { data.put("retireAge", 35); data.put("team", "Cleveland Cavaliers"); Parser parser = Parsers.create(ccl, data); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -702,7 +702,7 @@ public void testParseCclBetweenWithFirstReference() { data.put("age", 30); data.put("team", "Cleveland Cavaliers"); Parser parser = Parsers.create(ccl, data); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } @@ -716,7 +716,7 @@ public void testParseCclBetweenWithSecondReference() { data.put("age", 30); data.put("team", "Cleveland Cavaliers"); Parser parser = Parsers.create(ccl, data); - Assert.assertEquals(Parsing.toPostfixNotation(criteria.getSymbols()), + Assert.assertEquals(Parsing.toPostfixNotation(criteria.symbols()), parser.order()); } From f89c83b02d0b694c75be9deb58eb9a082428d0d5 Mon Sep 17 00:00:00 2001 From: Jeff Nelson Date: Mon, 17 Jun 2019 08:52:48 -0400 Subject: [PATCH 08/10] set version number to 0.10.0 --- .version | 2 +- CHANGELOG.md | 2 +- README.md | 4 ++-- concourse-driver-java/README.md | 4 ++-- concourse-driver-php/composer.json | 2 +- interface/concourse.thrift | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.version b/.version index 3eefcb9dd5..78bc1abd14 100644 --- a/.version +++ b/.version @@ -1 +1 @@ -1.0.0 +0.10.0 diff --git a/CHANGELOG.md b/CHANGELOG.md index 65f593a648..7dc4f0ab43 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ ## Changelog -#### Version 1.0.0 (TBD) +#### Version 0.10.0 (TBD) * Added an iterative connection builder that is accessible using the `Concourse.at()` static factory method. * Refactored the `concourse-import` framework to take advantage of version `1.1.0+` of the `data-transform-api` which has a more flexible notion of data transformations. As a result of this change, the `Importables` utility class has been removed. Custom importers that extend `DelimitedLineImporter` can leverage the protected `parseObject` and `importLines` methods to hook into the extraction and import logic in a manner similar to what was possible using the `Importables` functions. * Added the `com.cinchapi.concourse.valididate.Keys` utility class which contains the `#isWritable` method that determines if a proposed key can be written to Concourse. diff --git a/README.md b/README.md index d2cb1d02fa..d05477e08a 100644 --- a/README.md +++ b/README.md @@ -1,13 +1,13 @@ # Concourse - ![](https://img.shields.io/badge/version-1.0.0-green.svg) + ![](https://img.shields.io/badge/version-0.10.0-green.svg) ![](https://img.shields.io/badge/status-alpha-orange.svg) ![](https://img.shields.io/badge/license-Apache%202-blue.svg) [![Join the chat at https://gitter.im/cinchapi/concourse](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/cinchapi/concourse?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![](https://circleci.com/gh/cinchapi/concourse.svg?style=shield&circle-token=954a20e6114d649b1b6a046d95b953e7d05d2e2f)](https://circleci.com/gh/cinchapi/concourse) > [Concourse](http://concoursedb.com) is a distributed database warehouse for transactions search and analytics across time. Developers prefer Concourse because it simplifies building misssion-critical systems with on-demand data intelligence. Furthermore, Concourse makes end-to-end data management trivial by requiring no extra infrastructure, no prior configuration and no continuous tuning–all of which greatly reduce costs, and allow developers to focus on core business problems. -This is version 1.0.0 of Concourse. +This is version 0.10.0 of Concourse. ## Quickstart ### Docker diff --git a/concourse-driver-java/README.md b/concourse-driver-java/README.md index 6b01a25ec0..2c572fcfad 100644 --- a/concourse-driver-java/README.md +++ b/concourse-driver-java/README.md @@ -12,14 +12,14 @@ The concourse jar is available at [Maven Central](http://search.maven.org/#searc } dependencies { - compile 'com.cinchapi:concourse-driver-java:1.0.0+' + compile 'com.cinchapi:concourse-driver-java:0.10.0+' } If you prefer to use another dependency manager like Maven or Ivy, then use the following project information when declaring the dependency: GroupId: com.cinchapi ArtifactId: concourse-driver-java - Version: 1.0.0+ + Version: 0.10.0+ Alternatively, you can [download](http://cinchapi.org/concourse/download-api) the latest jar and manually add it to your project's classpath. diff --git a/concourse-driver-php/composer.json b/concourse-driver-php/composer.json index e8d2bdddc3..539ac12624 100644 --- a/concourse-driver-php/composer.json +++ b/concourse-driver-php/composer.json @@ -1,7 +1,7 @@ { "name": "cinchapi/concourse-driver-php", "description": "Official PHP driver for Concourse", - "version": "1.0.0", + "version": "0.10.0", "type": "library", "keywords": ["concourse", "nosql", "bigdata"], "homepage": "http://concoursedb.com", diff --git a/interface/concourse.thrift b/interface/concourse.thrift index a727822b89..9cb355f4b7 100644 --- a/interface/concourse.thrift +++ b/interface/concourse.thrift @@ -48,7 +48,7 @@ namespace rb concourse.thrift # # As much as possible, try to preserve backward compatibility so that # Concourse Server can always talk to older drivers. -const string VERSION = "1.0.0" +const string VERSION = "0.10.0" # This value is passed over the wire to represent a null value, usually # for get/select methods where a key/record has no data. From 1e2428c17de4a4b384434ee8318256cff4839f02 Mon Sep 17 00:00:00 2001 From: Jonathan Barronville Date: Fri, 21 Jun 2019 15:18:26 -0400 Subject: [PATCH 09/10] Built the core pieces of the Node.js driver for Concourse. --- concourse-driver-node-js/LICENSE | 202 + concourse-driver-node-js/package-lock.json | 524 + concourse-driver-node-js/package.json | 42 + concourse-driver-node-js/src/client/errors.js | 92 + concourse-driver-node-js/src/client/index.js | 181 + concourse-driver-node-js/src/index.js | 7 + .../src/thrift/ConcourseService.js | 61727 +++++++++ .../src/thrift/ConcourseService.js.bak | 101112 +++++++++++++++ .../src/thrift/complex_types.js | 241 + .../src/thrift/concourse_types.js | 23 + .../src/thrift/data_types.js | 230 + .../src/thrift/exceptions_types.js | 365 + .../src/thrift/shared_types.js | 166 + .../src/utilities/convert.js | 20 + .../src/utilities/index.js | 5 + .../thrift-transformers/remove-server-code.js | 98 + ...ift-map-return-types-to-javascript-maps.js | 197 + interface/complex.thrift | 4 + interface/concourse.thrift | 4 + interface/data.thrift | 4 + interface/exceptions.thrift | 6 +- interface/shared.thrift | 4 + utils/compile-thrift-node-js.sh | 41 + 23 files changed, 165294 insertions(+), 1 deletion(-) create mode 100644 concourse-driver-node-js/LICENSE create mode 100644 concourse-driver-node-js/package-lock.json create mode 100644 concourse-driver-node-js/package.json create mode 100644 concourse-driver-node-js/src/client/errors.js create mode 100644 concourse-driver-node-js/src/client/index.js create mode 100644 concourse-driver-node-js/src/index.js create mode 100644 concourse-driver-node-js/src/thrift/ConcourseService.js create mode 100644 concourse-driver-node-js/src/thrift/ConcourseService.js.bak create mode 100644 concourse-driver-node-js/src/thrift/complex_types.js create mode 100644 concourse-driver-node-js/src/thrift/concourse_types.js create mode 100644 concourse-driver-node-js/src/thrift/data_types.js create mode 100644 concourse-driver-node-js/src/thrift/exceptions_types.js create mode 100644 concourse-driver-node-js/src/thrift/shared_types.js create mode 100644 concourse-driver-node-js/src/utilities/convert.js create mode 100644 concourse-driver-node-js/src/utilities/index.js create mode 100755 concourse-driver-node-js/tools/thrift-transformers/remove-server-code.js create mode 100755 concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js create mode 100755 utils/compile-thrift-node-js.sh diff --git a/concourse-driver-node-js/LICENSE b/concourse-driver-node-js/LICENSE new file mode 100644 index 0000000000..d645695673 --- /dev/null +++ b/concourse-driver-node-js/LICENSE @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/concourse-driver-node-js/package-lock.json b/concourse-driver-node-js/package-lock.json new file mode 100644 index 0000000000..32b31813e0 --- /dev/null +++ b/concourse-driver-node-js/package-lock.json @@ -0,0 +1,524 @@ +{ + "name": "@cinchapi/concourse-driver", + "version": "0.1.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@creditkarma/thrift-parser": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/@creditkarma/thrift-parser/-/thrift-parser-1.2.0.tgz", + "integrity": "sha512-mSRxjSXvU6sBfWhMBWXl7H/XEKWHQ7x+MUDLwyeFIwwX9UaZKPOc7TgGd0N78kcZtIMk82ArdxO6aFhqnBuNtg==", + "dev": true + }, + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "ansi-styles": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", + "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, + "requires": { + "color-convert": "^1.9.0" + } + }, + "ast-types": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.13.1.tgz", + "integrity": "sha512-b+EeK0WlzrSmpMw5jktWvQGxblpWnvMrV+vOp69RLjzGiHwWV0vgq75DPKtUjppKni3yWwSW8WLGV3Ch/XIWcQ==", + "dev": true + }, + "async-limiter": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.0.tgz", + "integrity": "sha512-jp/uFnooOiO+L211eZOoSyzpOITMXx1rBITauYykG3BRYPu8h0UcxsPNB04RR5vo4Tyz3+ay17tR6JVf9qzYWg==" + }, + "bluebird": { + "version": "3.5.5", + "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.5.tgz", + "integrity": "sha512-5am6HnnfN+urzt4yfg7IgTbotDjIT/u8AJpEt0sIU9FtXfVeezXAPKswrG+xKUCOYAINpSdgZVDU6QFh+cuH3w==" + }, + "camelcase": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", + "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", + "dev": true + }, + "cliui": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", + "dev": true, + "requires": { + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + } + }, + "color-convert": { + "version": "1.9.3", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", + "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", + "dev": true, + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", + "dev": true + }, + "cross-spawn": { + "version": "6.0.5", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", + "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", + "dev": true, + "requires": { + "nice-try": "^1.0.4", + "path-key": "^2.0.1", + "semver": "^5.5.0", + "shebang-command": "^1.2.0", + "which": "^1.2.9" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", + "dev": true + }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, + "end-of-stream": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.1.tgz", + "integrity": "sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q==", + "dev": true, + "requires": { + "once": "^1.4.0" + } + }, + "esprima": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", + "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true + }, + "execa": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz", + "integrity": "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==", + "dev": true, + "requires": { + "cross-spawn": "^6.0.0", + "get-stream": "^4.0.0", + "is-stream": "^1.1.0", + "npm-run-path": "^2.0.0", + "p-finally": "^1.0.0", + "signal-exit": "^3.0.0", + "strip-eof": "^1.0.0" + } + }, + "find-up": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", + "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", + "dev": true, + "requires": { + "locate-path": "^3.0.0" + } + }, + "get-caller-file": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", + "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", + "dev": true + }, + "get-stream": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", + "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", + "dev": true, + "requires": { + "pump": "^3.0.0" + } + }, + "invert-kv": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", + "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==", + "dev": true + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", + "dev": true + }, + "is-stream": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", + "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=", + "dev": true + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", + "dev": true + }, + "java-properties": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/java-properties/-/java-properties-1.0.1.tgz", + "integrity": "sha512-HbTaaXlIHoDVNXjmp4flOBWOfYBkrVN8dD1tp4m+95M/ADSDW/BxWbiwyVIhw/2+5d0cof4PHZCbE7+S1ukTQw==" + }, + "lcid": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz", + "integrity": "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==", + "dev": true, + "requires": { + "invert-kv": "^2.0.0" + } + }, + "locate-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", + "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", + "dev": true, + "requires": { + "p-locate": "^3.0.0", + "path-exists": "^3.0.0" + } + }, + "lodash": { + "version": "4.17.11", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", + "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" + }, + "map-age-cleaner": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", + "integrity": "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==", + "dev": true, + "requires": { + "p-defer": "^1.0.0" + } + }, + "mem": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz", + "integrity": "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==", + "dev": true, + "requires": { + "map-age-cleaner": "^0.1.1", + "mimic-fn": "^2.0.0", + "p-is-promise": "^2.0.0" + } + }, + "mimic-fn": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true + }, + "nice-try": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", + "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", + "dev": true + }, + "node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha1-h6kGXNs1XTGC2PlM4RGIuCXGijs=" + }, + "npm-run-path": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", + "integrity": "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=", + "dev": true, + "requires": { + "path-key": "^2.0.0" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "dev": true, + "requires": { + "wrappy": "1" + } + }, + "os-locale": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz", + "integrity": "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==", + "dev": true, + "requires": { + "execa": "^1.0.0", + "lcid": "^2.0.0", + "mem": "^4.0.0" + } + }, + "p-defer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz", + "integrity": "sha1-n26xgvbJqozXQwBKfU+WsZaw+ww=", + "dev": true + }, + "p-finally": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", + "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=", + "dev": true + }, + "p-is-promise": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz", + "integrity": "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==", + "dev": true + }, + "p-limit": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz", + "integrity": "sha512-pZbTJpoUsCzV48Mc9Nh51VbwO0X9cuPFE8gYwx9BTCt9SF8/b7Zljd2fVgOxhIF/HDTKgpVzs+GPhyKfjLLFRQ==", + "dev": true, + "requires": { + "p-try": "^2.0.0" + } + }, + "p-locate": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", + "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", + "dev": true, + "requires": { + "p-limit": "^2.0.0" + } + }, + "p-try": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", + "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", + "dev": true + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true + }, + "path-key": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", + "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", + "dev": true + }, + "private": { + "version": "0.1.8", + "resolved": "https://registry.npmjs.org/private/-/private-0.1.8.tgz", + "integrity": "sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg==", + "dev": true + }, + "pump": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", + "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dev": true, + "requires": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "q": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", + "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=" + }, + "recast": { + "version": "0.18.1", + "resolved": "https://registry.npmjs.org/recast/-/recast-0.18.1.tgz", + "integrity": "sha512-Ri42yIOwHetqKgEhQSS4N1B9wSLn+eYcyLoQfuSpvd661Jty1Q3P0FXkzjIQ9XxTN+3+kRu1JFXbRmUCUmde5Q==", + "dev": true, + "requires": { + "ast-types": "0.13.1", + "esprima": "~4.0.0", + "private": "^0.1.8", + "source-map": "~0.6.1" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", + "dev": true + }, + "require-main-filename": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz", + "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", + "dev": true + }, + "semver": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz", + "integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==", + "dev": true + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", + "dev": true + }, + "shebang-command": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", + "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", + "dev": true, + "requires": { + "shebang-regex": "^1.0.0" + } + }, + "shebang-regex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", + "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", + "dev": true + }, + "signal-exit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", + "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=", + "dev": true + }, + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + }, + "strip-eof": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", + "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=", + "dev": true + }, + "thrift": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/thrift/-/thrift-0.12.0.tgz", + "integrity": "sha512-qE9PZi4XSbSQLz/sNxj6+ZiiFQYgbM4GmlO3CS/EVJBjCVfd46Zw0aiVIqOvVn74M7XUGyjOs2chAOwK4d4/hQ==", + "requires": { + "node-int64": "^0.4.0", + "q": "^1.5.0", + "ws": "^5.0.0" + } + }, + "which": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", + "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, + "requires": { + "isexe": "^2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", + "dev": true + }, + "wrap-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", + "dev": true, + "requires": { + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", + "dev": true + }, + "ws": { + "version": "5.2.2", + "resolved": "https://registry.npmjs.org/ws/-/ws-5.2.2.tgz", + "integrity": "sha512-jaHFD6PFv6UgoIVda6qZllptQsMlDEJkTQcybzzXDYM1XO9Y8em691FGMPmM46WGyLU4z9KMgQN+qrux/nhlHA==", + "requires": { + "async-limiter": "~1.0.0" + } + }, + "y18n": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", + "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", + "dev": true + }, + "yargs": { + "version": "13.2.4", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.2.4.tgz", + "integrity": "sha512-HG/DWAJa1PAnHT9JAhNa8AbAv3FPaiLzioSjCcmuXXhP8MlpHO5vwls4g4j6n30Z74GVQj8Xa62dWVx1QCGklg==", + "dev": true, + "requires": { + "cliui": "^5.0.0", + "find-up": "^3.0.0", + "get-caller-file": "^2.0.1", + "os-locale": "^3.1.0", + "require-directory": "^2.1.1", + "require-main-filename": "^2.0.0", + "set-blocking": "^2.0.0", + "string-width": "^3.0.0", + "which-module": "^2.0.0", + "y18n": "^4.0.0", + "yargs-parser": "^13.1.0" + } + }, + "yargs-parser": { + "version": "13.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz", + "integrity": "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==", + "dev": true, + "requires": { + "camelcase": "^5.0.0", + "decamelize": "^1.2.0" + } + } + } +} diff --git a/concourse-driver-node-js/package.json b/concourse-driver-node-js/package.json new file mode 100644 index 0000000000..f1d5b0b604 --- /dev/null +++ b/concourse-driver-node-js/package.json @@ -0,0 +1,42 @@ +{ + "author": "Jonathan Barronville (https://cinchapi.com)", + "bugs": "https://github.com/cinchapi/concourse/issues", + "dependencies": { + "bluebird": "^3.5.5", + "java-properties": "^1.0.1", + "lodash": "^4.17.11", + "thrift": "^0.12.0" + }, + "description": "The Node.js driver for the Concourse database system.", + "devDependencies": { + "@creditkarma/thrift-parser": "^1.2.0", + "ast-types": "^0.13.1", + "recast": "^0.18.1", + "yargs": "^13.2.4" + }, + "directories": { + "lib": "./src" + }, + "engines": { + "node": ">=6.5.0" + }, + "homepage": "http://concoursedb.com", + "keywords": [ + "analytics", + "cinchapi", + "concourse", + "database", + "nosql" + ], + "license": "Apache-2.0", + "main": "./src/index.js", + "name": "@cinchapi/concourse-driver", + "private": true, + "repository": { + "directory": "concourse-driver-node-js", + "type": "git", + "url": "https://github.com/cinchapi/concourse.git" + }, + "scripts": {}, + "version": "0.1.0" +} diff --git a/concourse-driver-node-js/src/client/errors.js b/concourse-driver-node-js/src/client/errors.js new file mode 100644 index 0000000000..0c063b4356 --- /dev/null +++ b/concourse-driver-node-js/src/client/errors.js @@ -0,0 +1,92 @@ +'use strict' + +const _$assign = require('lodash/assign') +const _$isFunction = require('lodash/isFunction') +const _$pick = require('lodash/pick') + +class ConnectionError extends Error { + constructor(options) { + options = _$assign({}, { + host: null, + originalError: null, + port: null + }, options) + options = _$pick(options, [ + 'host', + 'originalError', + 'port' + ]) + const message = `There was error connecting to the Concourse Server at ${options.host}:${options.port}` + Error.call(this, message) + Object.defineProperties(this, { + extra: { + enumerable: true, + value: _$assign({}, options) + }, + message: { + enumerable: true, + value: message + }, + name: { + enumerable: true, + value: `Client.${this.constructor.name}` + } + }) + Object.freeze(this.extra) + if (_$isFunction(Error.captureStackTrace)) { + Error.captureStackTrace(this, this.constructor) + } else { + const { stack } = new Error(message) + Object.defineProperty(this, 'stack', { + enumerable: true, + value: stack + }) + } + } +} + +class ThriftClientMethodError extends Error { + constructor(options) { + options = _$assign({}, { + arguments: null, + error: null, + method: null + }, options) + options = _$pick(options, [ + 'arguments', + 'error', + 'method' + ]) + const message = `There was error calling the method \`${options.method}\` on the Thrift client` + Error.call(this, message) + Object.defineProperties(this, { + extra: { + enumerable: true, + value: _$assign({}, options) + }, + message: { + enumerable: true, + value: message + }, + name: { + enumerable: true, + value: `Client.${this.constructor.name}` + } + }) + Object.freeze(this.extra) + if (_$isFunction(Error.captureStackTrace)) { + Error.captureStackTrace(this, this.constructor) + } else { + const { stack } = new Error(message) + Object.defineProperty(this, 'stack', { + enumerable: true, + value: stack + }) + } + } +} + +exports = module.exports = { + ConnectionError, + ThriftClientMethodError +} diff --git a/concourse-driver-node-js/src/client/index.js b/concourse-driver-node-js/src/client/index.js new file mode 100644 index 0000000000..348832c1e4 --- /dev/null +++ b/concourse-driver-node-js/src/client/index.js @@ -0,0 +1,181 @@ +'use strict' + +const _$assign = require('lodash/assign') +const _$forEach = require('lodash/forEach') +const _$isArray = require('lodash/isArray') +const _$isNumber = require('lodash/isNumber') +const _$isString = require('lodash/isString') +const _$isUndefined = require('lodash/isUndefined') +const _$pick = require('lodash/pick') +const ConcourseThriftService = require('../thrift/ConcourseService') +const errors = require('./errors') +const javaProperties = require('java-properties') +const path = require('path') +const Promise = require('bluebird') +const thrift = require('thrift') +const utilities = require('../utilities') + +class Client { + constructor(options) { + return (async (options) => { + options = _$assign({}, options) + const defaultOptions = { + environment: '', + host: 'localhost', + password: 'admin', + port: 1717, + username: 'admin' + } + if (_$isString(options.prefs)) { + options.prefs = path.resolve(options.prefs) + const preferencesFileProperties = javaProperties.of(options.prefs) + delete options.prefs + const preferencesFileOptions = { + environment: preferencesFileProperties.get('environment'), + host: preferencesFileProperties.get('host'), + password: preferencesFileProperties.get('password'), + port: preferencesFileProperties.getInt('port'), + username: preferencesFileProperties.get('username') + } + _$forEach(defaultOptions, (defaultOptionValue, optionKey) => { + if (_$isUndefined(options[optionKey])) { + options[optionKey] = (! _$isUndefined(preferencesFileOptions[optionKey])) ? preferencesFileOptions[optionKey] : defaultOptionValue + } + }) + } else { + _$forEach(defaultOptions, (defaultOptionValue, optionKey) => { + options[optionKey] = (! _$isUndefined(options[optionKey])) ? options[optionKey] : defaultOptionValue + }) + } + options = _$pick(options, [ + 'environment', + 'host', + 'password', + 'port', + 'username' + ]) + _$forEach(options, (optionValue, optionKey) => { + Object.defineProperty(this, optionKey, { value: optionValue }) + }) + await this.connect() + Object.defineProperty(this, 'credentials', { + value: await this.authenticate() + }) + Object.defineProperty(this, 'transaction', { + value: null, + writable: true + }) + return this + })(options) + } + + async _callThriftClientMethod(name, arguments_, reject) { + try { + return await this.client[name](...arguments_) + } catch (error) { + error = new Client.ThriftClientMethodError({ + arguments: arguments_, + error, + method: name + }) + reject(error) + } + } + + async authenticate() { + return new Promise(async (resolve, reject) => { + const credentials = await this._callThriftClientMethod('login', [ + this.username, + this.password, + this.environment + ], reject) + if (_$isUndefined(credentials)) { + return + } + resolve(credentials) + }) + } + + async connect() { + return new Promise((resolve, reject) => { + Object.defineProperty(this, 'connection', { + value: thrift.createConnection(this.host, this.port, { + protocol: thrift.TBinaryProtocol, + transport: thrift.TBufferedTransport + }) + }) + this.connection.on('error', (error) => { + error = new Client.ConnectionError({ + host: this.host, + originalError: error, + port: this.port + }) + reject(error) + }) + Object.defineProperty(this, 'client', { + value: thrift.createClient(ConcourseThriftService.Client, this.connection) + }) + this.connection.on('connect', () => { + resolve() + }) + }) + } + + select(options) { + return new Promise(async (resolve, reject) => { + options = _$assign({}, options) + let { criteria } = options + const keys = (! _$isUndefined(options.keys)) ? options.keys : options.key + let records = (! _$isUndefined(options.records)) ? options.records : options.record + const { timestamp } = options + let data + if (_$isArray(records) && + _$isUndefined(keys) && + _$isUndefined(timestamp)) { + data = await this._callThriftClientMethod('selectRecords', [ + records, + this.credentials, + this.transaction, + this.environment + ], reject) + if (_$isUndefined(data)) { return } + } else if (_$isArray(records) && + _$isNumber(timestamp) && + _$isUndefined(keys)) { + data = await this._callThriftClientMethod('selectRecordsTime', [ + records, + timestamp, + this.credentials, + this.transaction, + this.environment + ], reject) + if (_$isUndefined(data)) { return } + } else if (_$isArray(records) && + _$isString(timestamp) && + _$isUndefined(keys)) { + data = await this._callThriftClientMethod('selectRecordsTimestr', [ + records, + timestamp, + this.credentials, + this.transaction, + this.environment + ], reject) + if (_$isUndefined(data)) { return } + }// else if () { + // + //} + data = utilities.Convert.javascriptify(data) + resolve(data) + }) + } + + toString() { + return `Connected to ${this.host}:${this.port} as ${this.username}` + } +} + +_$assign(Client, errors) + +Client.connect = (...args) => new Client(...args) + +exports = module.exports = Client diff --git a/concourse-driver-node-js/src/index.js b/concourse-driver-node-js/src/index.js new file mode 100644 index 0000000000..6ecd8f0340 --- /dev/null +++ b/concourse-driver-node-js/src/index.js @@ -0,0 +1,7 @@ +'use strict' + +const Client = require('./client') + +const ConcourseDriver = { Client } + +exports = module.exports = ConcourseDriver diff --git a/concourse-driver-node-js/src/thrift/ConcourseService.js b/concourse-driver-node-js/src/thrift/ConcourseService.js new file mode 100644 index 0000000000..4ef9a18e0c --- /dev/null +++ b/concourse-driver-node-js/src/thrift/ConcourseService.js @@ -0,0 +1,61727 @@ +// +// Autogenerated by Thrift Compiler (0.12.0) +// +// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING +// +"use strict"; + +const thrift = require('thrift'); +const Thrift = thrift.Thrift; + +const data_ttypes = require('./data_types'); +const shared_ttypes = require('./shared_types'); +const exceptions_ttypes = require('./exceptions_types'); +const complex_ttypes = require('./complex_types'); + + +const ttypes = require('./concourse_types'); +//HELPER FUNCTIONS AND STRUCTURES + +const ConcourseService_abort_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_abort_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_abort_result = class { + constructor(args) { + this.ex = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_addKeyValue_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValue_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_addKeyValue_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_addKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_addKeyValueRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_addKeyValueRecords_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValueRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter4 in this.records) { + if (this.records.hasOwnProperty(iter4)) { + iter4 = this.records[iter4]; + output.writeI64(iter4); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_addKeyValueRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp36 = input.readMapBegin(); + const _size5 = _rtmp36.size || 0; + for (let _i7 = 0; _i7 < _size5; ++_i7) { + let key8 = null; + let val9 = null; + key8 = input.readI64(); + val9 = input.readBool(); + this.success[key8] = val9; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp313 = input.readMapBegin(); + const _size12 = _rtmp313.size || 0; + for (let _i14 = 0; _i14 < _size12; ++_i14) { + let key15 = null; + let val16 = null; + key15 = input.readI64(); + val16 = input.readString(); + this.success[key15] = val16; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStart_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStart_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp320 = input.readMapBegin(); + const _size19 = _rtmp320.size || 0; + for (let _i21 = 0; _i21 < _size19; ++_i21) { + let key22 = null; + let val23 = null; + key22 = input.readI64(); + val23 = input.readString(); + this.success[key22] = val23; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStartstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp327 = input.readMapBegin(); + const _size26 = _rtmp327.size || 0; + for (let _i28 = 0; _i28 < _size26; ++_i28) { + let key29 = null; + let val30 = null; + key29 = input.readI64(); + val30 = input.readString(); + this.success[key29] = val30; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStartEnd_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartEnd_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 3); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp334 = input.readMapBegin(); + const _size33 = _rtmp334.size || 0; + for (let _i35 = 0; _i35 < _size33; ++_i35) { + let key36 = null; + let val37 = null; + key36 = input.readI64(); + val37 = input.readString(); + this.success[key36] = val37; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStartstrEndstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartstrEndstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 3); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp341 = input.readMapBegin(); + const _size40 = _rtmp341.size || 0; + for (let _i42 = 0; _i42 < _size40; ++_i42) { + let key43 = null; + let val44 = null; + key43 = input.readI64(); + val44 = input.readString(); + this.success[key43] = val44; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp348 = input.readMapBegin(); + const _size47 = _rtmp348.size || 0; + for (let _i49 = 0; _i49 < _size47; ++_i49) { + let key50 = null; + let val51 = null; + key50 = input.readI64(); + val51 = input.readString(); + this.success[key50] = val51; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStart_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp355 = input.readMapBegin(); + const _size54 = _rtmp355.size || 0; + for (let _i56 = 0; _i56 < _size54; ++_i56) { + let key57 = null; + let val58 = null; + key57 = input.readI64(); + val58 = input.readString(); + this.success[key57] = val58; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStartstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp362 = input.readMapBegin(); + const _size61 = _rtmp362.size || 0; + for (let _i63 = 0; _i63 < _size61; ++_i63) { + let key64 = null; + let val65 = null; + key64 = input.readI64(); + val65 = input.readString(); + this.success[key64] = val65; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStartEnd_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 4); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp369 = input.readMapBegin(); + const _size68 = _rtmp369.size || 0; + for (let _i70 = 0; _i70 < _size68; ++_i70) { + let key71 = null; + let val72 = null; + key71 = input.readI64(); + val72 = input.readString(); + this.success[key71] = val72; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 4); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_auditKeyRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp376 = input.readMapBegin(); + const _size75 = _rtmp376.size || 0; + for (let _i77 = 0; _i77 < _size75; ++_i77) { + let key78 = null; + let val79 = null; + key78 = input.readI64(); + val79 = input.readString(); + this.success[key78] = val79; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_browseKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_browseKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp383 = input.readMapBegin(); + const _size82 = _rtmp383.size || 0; + for (let _i84 = 0; _i84 < _size82; ++_i84) { + let key85 = null; + let val86 = null; + key85 = new data_ttypes.TObject(); + key85.read(input); + val86 = []; + const _rtmp388 = input.readSetBegin(); + const _size87 = _rtmp388.size || 0; + for (let _i89 = 0; _i89 < _size87; ++_i89) { + let elem90 = null; + elem90 = input.readI64(); + val86.push(elem90); + } + input.readSetEnd(); + this.success[key85] = val86; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_browseKeys_args = class { + constructor(args) { + this.keys = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeys_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter98 in this.keys) { + if (this.keys.hasOwnProperty(iter98)) { + iter98 = this.keys[iter98]; + output.writeString(iter98); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_browseKeys_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3100 = input.readMapBegin(); + const _size99 = _rtmp3100.size || 0; + for (let _i101 = 0; _i101 < _size99; ++_i101) { + let key102 = null; + let val103 = null; + key102 = input.readString(); + val103 = {}; + const _rtmp3105 = input.readMapBegin(); + const _size104 = _rtmp3105.size || 0; + for (let _i106 = 0; _i106 < _size104; ++_i106) { + let key107 = null; + let val108 = null; + key107 = new data_ttypes.TObject(); + key107.read(input); + val108 = []; + const _rtmp3110 = input.readSetBegin(); + const _size109 = _rtmp3110.size || 0; + for (let _i111 = 0; _i111 < _size109; ++_i111) { + let elem112 = null; + elem112 = input.readI64(); + val108.push(elem112); + } + input.readSetEnd(); + val103[key107] = val108; + } + input.readMapEnd(); + this.success[key102] = val103; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_browseKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_browseKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3119 = input.readMapBegin(); + const _size118 = _rtmp3119.size || 0; + for (let _i120 = 0; _i120 < _size118; ++_i120) { + let key121 = null; + let val122 = null; + key121 = new data_ttypes.TObject(); + key121.read(input); + val122 = []; + const _rtmp3124 = input.readSetBegin(); + const _size123 = _rtmp3124.size || 0; + for (let _i125 = 0; _i125 < _size123; ++_i125) { + let elem126 = null; + elem126 = input.readI64(); + val122.push(elem126); + } + input.readSetEnd(); + this.success[key121] = val122; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_browseKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_browseKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3131 = input.readMapBegin(); + const _size130 = _rtmp3131.size || 0; + for (let _i132 = 0; _i132 < _size130; ++_i132) { + let key133 = null; + let val134 = null; + key133 = new data_ttypes.TObject(); + key133.read(input); + val134 = []; + const _rtmp3136 = input.readSetBegin(); + const _size135 = _rtmp3136.size || 0; + for (let _i137 = 0; _i137 < _size135; ++_i137) { + let elem138 = null; + elem138 = input.readI64(); + val134.push(elem138); + } + input.readSetEnd(); + this.success[key133] = val134; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_browseKeysTime_args = class { + constructor(args) { + this.keys = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeysTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter146 in this.keys) { + if (this.keys.hasOwnProperty(iter146)) { + iter146 = this.keys[iter146]; + output.writeString(iter146); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_browseKeysTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3148 = input.readMapBegin(); + const _size147 = _rtmp3148.size || 0; + for (let _i149 = 0; _i149 < _size147; ++_i149) { + let key150 = null; + let val151 = null; + key150 = input.readString(); + val151 = {}; + const _rtmp3153 = input.readMapBegin(); + const _size152 = _rtmp3153.size || 0; + for (let _i154 = 0; _i154 < _size152; ++_i154) { + let key155 = null; + let val156 = null; + key155 = new data_ttypes.TObject(); + key155.read(input); + val156 = []; + const _rtmp3158 = input.readSetBegin(); + const _size157 = _rtmp3158.size || 0; + for (let _i159 = 0; _i159 < _size157; ++_i159) { + let elem160 = null; + elem160 = input.readI64(); + val156.push(elem160); + } + input.readSetEnd(); + val151[key155] = val156; + } + input.readMapEnd(); + this.success[key150] = val151; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_browseKeysTimestr_args = class { + constructor(args) { + this.keys = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeysTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter170 in this.keys) { + if (this.keys.hasOwnProperty(iter170)) { + iter170 = this.keys[iter170]; + output.writeString(iter170); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_browseKeysTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3172 = input.readMapBegin(); + const _size171 = _rtmp3172.size || 0; + for (let _i173 = 0; _i173 < _size171; ++_i173) { + let key174 = null; + let val175 = null; + key174 = input.readString(); + val175 = {}; + const _rtmp3177 = input.readMapBegin(); + const _size176 = _rtmp3177.size || 0; + for (let _i178 = 0; _i178 < _size176; ++_i178) { + let key179 = null; + let val180 = null; + key179 = new data_ttypes.TObject(); + key179.read(input); + val180 = []; + const _rtmp3182 = input.readSetBegin(); + const _size181 = _rtmp3182.size || 0; + for (let _i183 = 0; _i183 < _size181; ++_i183) { + let elem184 = null; + elem184 = input.readI64(); + val180.push(elem184); + } + input.readSetEnd(); + val175[key179] = val180; + } + input.readMapEnd(); + this.success[key174] = val175; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3191 = input.readMapBegin(); + const _size190 = _rtmp3191.size || 0; + for (let _i192 = 0; _i192 < _size190; ++_i192) { + let key193 = null; + let val194 = null; + key193 = input.readI64(); + val194 = []; + const _rtmp3196 = input.readSetBegin(); + const _size195 = _rtmp3196.size || 0; + for (let _i197 = 0; _i197 < _size195; ++_i197) { + let elem198 = null; + elem198 = new data_ttypes.TObject(); + elem198.read(input); + val194.push(elem198); + } + input.readSetEnd(); + this.success[key193] = val194; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStart_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3203 = input.readMapBegin(); + const _size202 = _rtmp3203.size || 0; + for (let _i204 = 0; _i204 < _size202; ++_i204) { + let key205 = null; + let val206 = null; + key205 = input.readI64(); + val206 = []; + const _rtmp3208 = input.readSetBegin(); + const _size207 = _rtmp3208.size || 0; + for (let _i209 = 0; _i209 < _size207; ++_i209) { + let elem210 = null; + elem210 = new data_ttypes.TObject(); + elem210.read(input); + val206.push(elem210); + } + input.readSetEnd(); + this.success[key205] = val206; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStartstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3215 = input.readMapBegin(); + const _size214 = _rtmp3215.size || 0; + for (let _i216 = 0; _i216 < _size214; ++_i216) { + let key217 = null; + let val218 = null; + key217 = input.readI64(); + val218 = []; + const _rtmp3220 = input.readSetBegin(); + const _size219 = _rtmp3220.size || 0; + for (let _i221 = 0; _i221 < _size219; ++_i221) { + let elem222 = null; + elem222 = new data_ttypes.TObject(); + elem222.read(input); + val218.push(elem222); + } + input.readSetEnd(); + this.success[key217] = val218; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStartEnd_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 4); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3227 = input.readMapBegin(); + const _size226 = _rtmp3227.size || 0; + for (let _i228 = 0; _i228 < _size226; ++_i228) { + let key229 = null; + let val230 = null; + key229 = input.readI64(); + val230 = []; + const _rtmp3232 = input.readSetBegin(); + const _size231 = _rtmp3232.size || 0; + for (let _i233 = 0; _i233 < _size231; ++_i233) { + let elem234 = null; + elem234 = new data_ttypes.TObject(); + elem234.read(input); + val230.push(elem234); + } + input.readSetEnd(); + this.success[key229] = val230; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 4); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_chronologizeKeyRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3239 = input.readMapBegin(); + const _size238 = _rtmp3239.size || 0; + for (let _i240 = 0; _i240 < _size238; ++_i240) { + let key241 = null; + let val242 = null; + key241 = input.readI64(); + val242 = []; + const _rtmp3244 = input.readSetBegin(); + const _size243 = _rtmp3244.size || 0; + for (let _i245 = 0; _i245 < _size243; ++_i245) { + let elem246 = null; + elem246 = new data_ttypes.TObject(); + elem246.read(input); + val242.push(elem246); + } + input.readSetEnd(); + this.success[key241] = val242; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_clearRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_clearRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_clearRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_clearRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_clearRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter254 in this.records) { + if (this.records.hasOwnProperty(iter254)) { + iter254 = this.records[iter254]; + output.writeI64(iter254); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_clearRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_clearKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_clearKeyRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_clearKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter259 in this.keys) { + if (this.keys.hasOwnProperty(iter259)) { + iter259 = this.keys[iter259]; + output.writeString(iter259); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_clearKeysRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_clearKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter264 in this.records) { + if (this.records.hasOwnProperty(iter264)) { + iter264 = this.records[iter264]; + output.writeI64(iter264); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_clearKeyRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_clearKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter273 in this.keys) { + if (this.keys.hasOwnProperty(iter273)) { + iter273 = this.keys[iter273]; + output.writeString(iter273); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter274 in this.records) { + if (this.records.hasOwnProperty(iter274)) { + iter274 = this.records[iter274]; + output.writeI64(iter274); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_clearKeysRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_commit_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_commit_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_commit_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describe_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describe_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describe_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3276 = input.readSetBegin(); + const _size275 = _rtmp3276.size || 0; + for (let _i277 = 0; _i277 < _size275; ++_i277) { + let elem278 = null; + elem278 = input.readString(); + this.success.push(elem278); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeTime_args = class { + constructor(args) { + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeTime_args'); + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 1); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3281 = input.readSetBegin(); + const _size280 = _rtmp3281.size || 0; + for (let _i282 = 0; _i282 < _size280; ++_i282) { + let elem283 = null; + elem283 = input.readString(); + this.success.push(elem283); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeTimestr_args = class { + constructor(args) { + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeTimestr_args'); + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 1); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3286 = input.readSetBegin(); + const _size285 = _rtmp3286.size || 0; + for (let _i287 = 0; _i287 < _size285; ++_i287) { + let elem288 = null; + elem288 = input.readString(); + this.success.push(elem288); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3291 = input.readSetBegin(); + const _size290 = _rtmp3291.size || 0; + for (let _i292 = 0; _i292 < _size290; ++_i292) { + let elem293 = null; + elem293 = input.readString(); + this.success.push(elem293); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeRecordTime_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordTime_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3296 = input.readSetBegin(); + const _size295 = _rtmp3296.size || 0; + for (let _i297 = 0; _i297 < _size295; ++_i297) { + let elem298 = null; + elem298 = input.readString(); + this.success.push(elem298); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeRecordTimestr_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordTimestr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3301 = input.readSetBegin(); + const _size300 = _rtmp3301.size || 0; + for (let _i302 = 0; _i302 < _size300; ++_i302) { + let elem303 = null; + elem303 = input.readString(); + this.success.push(elem303); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter309 in this.records) { + if (this.records.hasOwnProperty(iter309)) { + iter309 = this.records[iter309]; + output.writeI64(iter309); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3311 = input.readMapBegin(); + const _size310 = _rtmp3311.size || 0; + for (let _i312 = 0; _i312 < _size310; ++_i312) { + let key313 = null; + let val314 = null; + key313 = input.readI64(); + val314 = []; + const _rtmp3316 = input.readSetBegin(); + const _size315 = _rtmp3316.size || 0; + for (let _i317 = 0; _i317 < _size315; ++_i317) { + let elem318 = null; + elem318 = input.readString(); + val314.push(elem318); + } + input.readSetEnd(); + this.success[key313] = val314; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeRecordsTime_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordsTime_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter326 in this.records) { + if (this.records.hasOwnProperty(iter326)) { + iter326 = this.records[iter326]; + output.writeI64(iter326); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3328 = input.readMapBegin(); + const _size327 = _rtmp3328.size || 0; + for (let _i329 = 0; _i329 < _size327; ++_i329) { + let key330 = null; + let val331 = null; + key330 = input.readI64(); + val331 = []; + const _rtmp3333 = input.readSetBegin(); + const _size332 = _rtmp3333.size || 0; + for (let _i334 = 0; _i334 < _size332; ++_i334) { + let elem335 = null; + elem335 = input.readString(); + val331.push(elem335); + } + input.readSetEnd(); + this.success[key330] = val331; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_describeRecordsTimestr_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordsTimestr_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter343 in this.records) { + if (this.records.hasOwnProperty(iter343)) { + iter343 = this.records[iter343]; + output.writeI64(iter343); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_describeRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3345 = input.readMapBegin(); + const _size344 = _rtmp3345.size || 0; + for (let _i346 = 0; _i346 < _size344; ++_i346) { + let key347 = null; + let val348 = null; + key347 = input.readI64(); + val348 = []; + const _rtmp3350 = input.readSetBegin(); + const _size349 = _rtmp3350.size || 0; + for (let _i351 = 0; _i351 < _size349; ++_i351) { + let elem352 = null; + elem352 = input.readString(); + val348.push(elem352); + } + input.readSetEnd(); + this.success[key347] = val348; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStart_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStart_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3357 = input.readMapBegin(); + const _size356 = _rtmp3357.size || 0; + for (let _i358 = 0; _i358 < _size356; ++_i358) { + let key359 = null; + let val360 = null; + key359 = input.readString(); + val360 = {}; + const _rtmp3362 = input.readMapBegin(); + const _size361 = _rtmp3362.size || 0; + for (let _i363 = 0; _i363 < _size361; ++_i363) { + let key364 = null; + let val365 = null; + key364 = input.readI32(); + val365 = []; + const _rtmp3367 = input.readSetBegin(); + const _size366 = _rtmp3367.size || 0; + for (let _i368 = 0; _i368 < _size366; ++_i368) { + let elem369 = null; + elem369 = new data_ttypes.TObject(); + elem369.read(input); + val365.push(elem369); + } + input.readSetEnd(); + val360[key364] = val365; + } + input.readMapEnd(); + this.success[key359] = val360; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStartstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3376 = input.readMapBegin(); + const _size375 = _rtmp3376.size || 0; + for (let _i377 = 0; _i377 < _size375; ++_i377) { + let key378 = null; + let val379 = null; + key378 = input.readString(); + val379 = {}; + const _rtmp3381 = input.readMapBegin(); + const _size380 = _rtmp3381.size || 0; + for (let _i382 = 0; _i382 < _size380; ++_i382) { + let key383 = null; + let val384 = null; + key383 = input.readI32(); + val384 = []; + const _rtmp3386 = input.readSetBegin(); + const _size385 = _rtmp3386.size || 0; + for (let _i387 = 0; _i387 < _size385; ++_i387) { + let elem388 = null; + elem388 = new data_ttypes.TObject(); + elem388.read(input); + val384.push(elem388); + } + input.readSetEnd(); + val379[key383] = val384; + } + input.readMapEnd(); + this.success[key378] = val379; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStartEnd_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartEnd_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 3); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3395 = input.readMapBegin(); + const _size394 = _rtmp3395.size || 0; + for (let _i396 = 0; _i396 < _size394; ++_i396) { + let key397 = null; + let val398 = null; + key397 = input.readString(); + val398 = {}; + const _rtmp3400 = input.readMapBegin(); + const _size399 = _rtmp3400.size || 0; + for (let _i401 = 0; _i401 < _size399; ++_i401) { + let key402 = null; + let val403 = null; + key402 = input.readI32(); + val403 = []; + const _rtmp3405 = input.readSetBegin(); + const _size404 = _rtmp3405.size || 0; + for (let _i406 = 0; _i406 < _size404; ++_i406) { + let elem407 = null; + elem407 = new data_ttypes.TObject(); + elem407.read(input); + val403.push(elem407); + } + input.readSetEnd(); + val398[key402] = val403; + } + input.readMapEnd(); + this.success[key397] = val398; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStartstrEndstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartstrEndstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 3); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3414 = input.readMapBegin(); + const _size413 = _rtmp3414.size || 0; + for (let _i415 = 0; _i415 < _size413; ++_i415) { + let key416 = null; + let val417 = null; + key416 = input.readString(); + val417 = {}; + const _rtmp3419 = input.readMapBegin(); + const _size418 = _rtmp3419.size || 0; + for (let _i420 = 0; _i420 < _size418; ++_i420) { + let key421 = null; + let val422 = null; + key421 = input.readI32(); + val422 = []; + const _rtmp3424 = input.readSetBegin(); + const _size423 = _rtmp3424.size || 0; + for (let _i425 = 0; _i425 < _size423; ++_i425) { + let elem426 = null; + elem426 = new data_ttypes.TObject(); + elem426.read(input); + val422.push(elem426); + } + input.readSetEnd(); + val417[key421] = val422; + } + input.readMapEnd(); + this.success[key416] = val417; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStart_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3433 = input.readMapBegin(); + const _size432 = _rtmp3433.size || 0; + for (let _i434 = 0; _i434 < _size432; ++_i434) { + let key435 = null; + let val436 = null; + key435 = input.readI32(); + val436 = []; + const _rtmp3438 = input.readSetBegin(); + const _size437 = _rtmp3438.size || 0; + for (let _i439 = 0; _i439 < _size437; ++_i439) { + let elem440 = null; + elem440 = new data_ttypes.TObject(); + elem440.read(input); + val436.push(elem440); + } + input.readSetEnd(); + this.success[key435] = val436; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStartstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3445 = input.readMapBegin(); + const _size444 = _rtmp3445.size || 0; + for (let _i446 = 0; _i446 < _size444; ++_i446) { + let key447 = null; + let val448 = null; + key447 = input.readI32(); + val448 = []; + const _rtmp3450 = input.readSetBegin(); + const _size449 = _rtmp3450.size || 0; + for (let _i451 = 0; _i451 < _size449; ++_i451) { + let elem452 = null; + elem452 = new data_ttypes.TObject(); + elem452.read(input); + val448.push(elem452); + } + input.readSetEnd(); + this.success[key447] = val448; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStartEnd_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 4); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3457 = input.readMapBegin(); + const _size456 = _rtmp3457.size || 0; + for (let _i458 = 0; _i458 < _size456; ++_i458) { + let key459 = null; + let val460 = null; + key459 = input.readI32(); + val460 = []; + const _rtmp3462 = input.readSetBegin(); + const _size461 = _rtmp3462.size || 0; + for (let _i463 = 0; _i463 < _size461; ++_i463) { + let elem464 = null; + elem464 = new data_ttypes.TObject(); + elem464.read(input); + val460.push(elem464); + } + input.readSetEnd(); + this.success[key459] = val460; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 4); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3469 = input.readMapBegin(); + const _size468 = _rtmp3469.size || 0; + for (let _i470 = 0; _i470 < _size468; ++_i470) { + let key471 = null; + let val472 = null; + key471 = input.readI32(); + val472 = []; + const _rtmp3474 = input.readSetBegin(); + const _size473 = _rtmp3474.size || 0; + for (let _i475 = 0; _i475 < _size473; ++_i475) { + let elem476 = null; + elem476 = new data_ttypes.TObject(); + elem476.read(input); + val472.push(elem476); + } + input.readSetEnd(); + this.success[key471] = val472; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStart_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3481 = input.readMapBegin(); + const _size480 = _rtmp3481.size || 0; + for (let _i482 = 0; _i482 < _size480; ++_i482) { + let key483 = null; + let val484 = null; + key483 = new data_ttypes.TObject(); + key483.read(input); + val484 = {}; + const _rtmp3486 = input.readMapBegin(); + const _size485 = _rtmp3486.size || 0; + for (let _i487 = 0; _i487 < _size485; ++_i487) { + let key488 = null; + let val489 = null; + key488 = input.readI32(); + val489 = []; + const _rtmp3491 = input.readSetBegin(); + const _size490 = _rtmp3491.size || 0; + for (let _i492 = 0; _i492 < _size490; ++_i492) { + let elem493 = null; + elem493 = input.readI64(); + val489.push(elem493); + } + input.readSetEnd(); + val484[key488] = val489; + } + input.readMapEnd(); + this.success[key483] = val484; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStartstr_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3500 = input.readMapBegin(); + const _size499 = _rtmp3500.size || 0; + for (let _i501 = 0; _i501 < _size499; ++_i501) { + let key502 = null; + let val503 = null; + key502 = new data_ttypes.TObject(); + key502.read(input); + val503 = {}; + const _rtmp3505 = input.readMapBegin(); + const _size504 = _rtmp3505.size || 0; + for (let _i506 = 0; _i506 < _size504; ++_i506) { + let key507 = null; + let val508 = null; + key507 = input.readI32(); + val508 = []; + const _rtmp3510 = input.readSetBegin(); + const _size509 = _rtmp3510.size || 0; + for (let _i511 = 0; _i511 < _size509; ++_i511) { + let elem512 = null; + elem512 = input.readI64(); + val508.push(elem512); + } + input.readSetEnd(); + val503[key507] = val508; + } + input.readMapEnd(); + this.success[key502] = val503; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStartEnd_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 3); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3519 = input.readMapBegin(); + const _size518 = _rtmp3519.size || 0; + for (let _i520 = 0; _i520 < _size518; ++_i520) { + let key521 = null; + let val522 = null; + key521 = new data_ttypes.TObject(); + key521.read(input); + val522 = {}; + const _rtmp3524 = input.readMapBegin(); + const _size523 = _rtmp3524.size || 0; + for (let _i525 = 0; _i525 < _size523; ++_i525) { + let key526 = null; + let val527 = null; + key526 = input.readI32(); + val527 = []; + const _rtmp3529 = input.readSetBegin(); + const _size528 = _rtmp3529.size || 0; + for (let _i530 = 0; _i530 < _size528; ++_i530) { + let elem531 = null; + elem531 = input.readI64(); + val527.push(elem531); + } + input.readSetEnd(); + val522[key526] = val527; + } + input.readMapEnd(); + this.success[key521] = val522; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 3); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_diffKeyStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3538 = input.readMapBegin(); + const _size537 = _rtmp3538.size || 0; + for (let _i539 = 0; _i539 < _size537; ++_i539) { + let key540 = null; + let val541 = null; + key540 = new data_ttypes.TObject(); + key540.read(input); + val541 = {}; + const _rtmp3543 = input.readMapBegin(); + const _size542 = _rtmp3543.size || 0; + for (let _i544 = 0; _i544 < _size542; ++_i544) { + let key545 = null; + let val546 = null; + key545 = input.readI32(); + val546 = []; + const _rtmp3548 = input.readSetBegin(); + const _size547 = _rtmp3548.size || 0; + for (let _i549 = 0; _i549 < _size547; ++_i549) { + let elem550 = null; + elem550 = input.readI64(); + val546.push(elem550); + } + input.readSetEnd(); + val541[key545] = val546; + } + input.readMapEnd(); + this.success[key540] = val541; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_invokePlugin_args = class { + constructor(args) { + this.id = null; + this.method = null; + this.params = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.id !== undefined && args.id !== null) { + this.id = args.id; + } + if (args.method !== undefined && args.method !== null) { + this.method = args.method; + } + if (args.params !== undefined && args.params !== null) { + this.params = Thrift.copyList(args.params, [complex_ttypes.ComplexTObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_invokePlugin_args'); + if (this.id !== null && this.id !== undefined) { + output.writeFieldBegin('id', Thrift.Type.STRING, 1); + output.writeString(this.id); + output.writeFieldEnd(); + } + if (this.method !== null && this.method !== undefined) { + output.writeFieldBegin('method', Thrift.Type.STRING, 2); + output.writeString(this.method); + output.writeFieldEnd(); + } + if (this.params !== null && this.params !== undefined) { + output.writeFieldBegin('params', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.params.length); + for (let iter560 in this.params) { + if (this.params.hasOwnProperty(iter560)) { + iter560 = this.params[iter560]; + iter560.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_invokePlugin_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new complex_ttypes.ComplexTObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new complex_ttypes.ComplexTObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_login_args = class { + constructor(args) { + this.username = null; + this.password = null; + this.environment = null; + if (args) { + if (args.username !== undefined && args.username !== null) { + this.username = args.username; + } + if (args.password !== undefined && args.password !== null) { + this.password = args.password; + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_login_args'); + if (this.username !== null && this.username !== undefined) { + output.writeFieldBegin('username', Thrift.Type.STRING, 1); + output.writeBinary(this.username); + output.writeFieldEnd(); + } + if (this.password !== null && this.password !== undefined) { + output.writeFieldBegin('password', Thrift.Type.STRING, 2); + output.writeBinary(this.password); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_login_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex2 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new shared_ttypes.AccessToken(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new shared_ttypes.AccessToken(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.PermissionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_logout_args = class { + constructor(args) { + this.token = null; + this.environment = null; + if (args) { + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.AccessToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_logout_args'); + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 1); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 2); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_logout_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex2 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.PermissionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_stage_args = class { + constructor(args) { + this.token = null; + this.environment = null; + if (args) { + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.AccessToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_stage_args'); + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 1); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 2); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_stage_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex2 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new shared_ttypes.TransactionToken(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new shared_ttypes.TransactionToken(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.PermissionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_insertJson_args = class { + constructor(args) { + this.json = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJson_args'); + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 1); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_insertJson_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3562 = input.readSetBegin(); + const _size561 = _rtmp3562.size || 0; + for (let _i563 = 0; _i563 < _size561; ++_i563) { + let elem564 = null; + elem564 = input.readI64(); + this.success.push(elem564); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_insertJsonRecord_args = class { + constructor(args) { + this.json = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJsonRecord_args'); + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 1); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_insertJsonRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_insertJsonRecords_args = class { + constructor(args) { + this.json = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJsonRecords_args'); + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 1); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter570 in this.records) { + if (this.records.hasOwnProperty(iter570)) { + iter570 = this.records[iter570]; + output.writeI64(iter570); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_insertJsonRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3572 = input.readMapBegin(); + const _size571 = _rtmp3572.size || 0; + for (let _i573 = 0; _i573 < _size571; ++_i573) { + let key574 = null; + let val575 = null; + key574 = input.readI64(); + val575 = input.readBool(); + this.success[key574] = val575; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_removeKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_removeKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_removeKeyValueRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_removeKeyValueRecords_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_removeKeyValueRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter582 in this.records) { + if (this.records.hasOwnProperty(iter582)) { + iter582 = this.records[iter582]; + output.writeI64(iter582); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_removeKeyValueRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3584 = input.readMapBegin(); + const _size583 = _rtmp3584.size || 0; + for (let _i585 = 0; _i585 < _size583; ++_i585) { + let key586 = null; + let val587 = null; + key586 = input.readI64(); + val587 = input.readBool(); + this.success[key586] = val587; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_setKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_setKeyValueRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_setKeyValue_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValue_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_setKeyValue_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_setKeyValueRecords_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValueRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter594 in this.records) { + if (this.records.hasOwnProperty(iter594)) { + iter594 = this.records[iter594]; + output.writeI64(iter594); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_setKeyValueRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_reconcileKeyRecordValues_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.values = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_reconcileKeyRecordValues_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.SET, 3); + output.writeSetBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter599 in this.values) { + if (this.values.hasOwnProperty(iter599)) { + iter599 = this.values[iter599]; + iter599.write(output); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_reconcileKeyRecordValues_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_inventory_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_inventory_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_inventory_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3601 = input.readSetBegin(); + const _size600 = _rtmp3601.size || 0; + for (let _i602 = 0; _i602 < _size600; ++_i602) { + let elem603 = null; + elem603 = input.readI64(); + this.success.push(elem603); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3606 = input.readMapBegin(); + const _size605 = _rtmp3606.size || 0; + for (let _i607 = 0; _i607 < _size605; ++_i607) { + let key608 = null; + let val609 = null; + key608 = input.readString(); + val609 = []; + const _rtmp3611 = input.readSetBegin(); + const _size610 = _rtmp3611.size || 0; + for (let _i612 = 0; _i612 < _size610; ++_i612) { + let elem613 = null; + elem613 = new data_ttypes.TObject(); + elem613.read(input); + val609.push(elem613); + } + input.readSetEnd(); + this.success[key608] = val609; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter621 in this.records) { + if (this.records.hasOwnProperty(iter621)) { + iter621 = this.records[iter621]; + output.writeI64(iter621); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3623 = input.readMapBegin(); + const _size622 = _rtmp3623.size || 0; + for (let _i624 = 0; _i624 < _size622; ++_i624) { + let key625 = null; + let val626 = null; + key625 = input.readI64(); + val626 = {}; + const _rtmp3628 = input.readMapBegin(); + const _size627 = _rtmp3628.size || 0; + for (let _i629 = 0; _i629 < _size627; ++_i629) { + let key630 = null; + let val631 = null; + key630 = input.readString(); + val631 = []; + const _rtmp3633 = input.readSetBegin(); + const _size632 = _rtmp3633.size || 0; + for (let _i634 = 0; _i634 < _size632; ++_i634) { + let elem635 = null; + elem635 = new data_ttypes.TObject(); + elem635.read(input); + val631.push(elem635); + } + input.readSetEnd(); + val626[key630] = val631; + } + input.readMapEnd(); + this.success[key625] = val626; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectRecordTime_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordTime_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3642 = input.readMapBegin(); + const _size641 = _rtmp3642.size || 0; + for (let _i643 = 0; _i643 < _size641; ++_i643) { + let key644 = null; + let val645 = null; + key644 = input.readString(); + val645 = []; + const _rtmp3647 = input.readSetBegin(); + const _size646 = _rtmp3647.size || 0; + for (let _i648 = 0; _i648 < _size646; ++_i648) { + let elem649 = null; + elem649 = new data_ttypes.TObject(); + elem649.read(input); + val645.push(elem649); + } + input.readSetEnd(); + this.success[key644] = val645; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectRecordTimestr_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordTimestr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3654 = input.readMapBegin(); + const _size653 = _rtmp3654.size || 0; + for (let _i655 = 0; _i655 < _size653; ++_i655) { + let key656 = null; + let val657 = null; + key656 = input.readString(); + val657 = []; + const _rtmp3659 = input.readSetBegin(); + const _size658 = _rtmp3659.size || 0; + for (let _i660 = 0; _i660 < _size658; ++_i660) { + let elem661 = null; + elem661 = new data_ttypes.TObject(); + elem661.read(input); + val657.push(elem661); + } + input.readSetEnd(); + this.success[key656] = val657; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectRecordsTime_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordsTime_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter669 in this.records) { + if (this.records.hasOwnProperty(iter669)) { + iter669 = this.records[iter669]; + output.writeI64(iter669); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3671 = input.readMapBegin(); + const _size670 = _rtmp3671.size || 0; + for (let _i672 = 0; _i672 < _size670; ++_i672) { + let key673 = null; + let val674 = null; + key673 = input.readI64(); + val674 = {}; + const _rtmp3676 = input.readMapBegin(); + const _size675 = _rtmp3676.size || 0; + for (let _i677 = 0; _i677 < _size675; ++_i677) { + let key678 = null; + let val679 = null; + key678 = input.readString(); + val679 = []; + const _rtmp3681 = input.readSetBegin(); + const _size680 = _rtmp3681.size || 0; + for (let _i682 = 0; _i682 < _size680; ++_i682) { + let elem683 = null; + elem683 = new data_ttypes.TObject(); + elem683.read(input); + val679.push(elem683); + } + input.readSetEnd(); + val674[key678] = val679; + } + input.readMapEnd(); + this.success[key673] = val674; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectRecordsTimestr_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordsTimestr_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter693 in this.records) { + if (this.records.hasOwnProperty(iter693)) { + iter693 = this.records[iter693]; + output.writeI64(iter693); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3695 = input.readMapBegin(); + const _size694 = _rtmp3695.size || 0; + for (let _i696 = 0; _i696 < _size694; ++_i696) { + let key697 = null; + let val698 = null; + key697 = input.readI64(); + val698 = {}; + const _rtmp3700 = input.readMapBegin(); + const _size699 = _rtmp3700.size || 0; + for (let _i701 = 0; _i701 < _size699; ++_i701) { + let key702 = null; + let val703 = null; + key702 = input.readString(); + val703 = []; + const _rtmp3705 = input.readSetBegin(); + const _size704 = _rtmp3705.size || 0; + for (let _i706 = 0; _i706 < _size704; ++_i706) { + let elem707 = null; + elem707 = new data_ttypes.TObject(); + elem707.read(input); + val703.push(elem707); + } + input.readSetEnd(); + val698[key702] = val703; + } + input.readMapEnd(); + this.success[key697] = val698; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3714 = input.readSetBegin(); + const _size713 = _rtmp3714.size || 0; + for (let _i715 = 0; _i715 < _size713; ++_i715) { + let elem716 = null; + elem716 = new data_ttypes.TObject(); + elem716.read(input); + this.success.push(elem716); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3719 = input.readSetBegin(); + const _size718 = _rtmp3719.size || 0; + for (let _i720 = 0; _i720 < _size718; ++_i720) { + let elem721 = null; + elem721 = new data_ttypes.TObject(); + elem721.read(input); + this.success.push(elem721); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3724 = input.readSetBegin(); + const _size723 = _rtmp3724.size || 0; + for (let _i725 = 0; _i725 < _size723; ++_i725) { + let elem726 = null; + elem726 = new data_ttypes.TObject(); + elem726.read(input); + this.success.push(elem726); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter732 in this.keys) { + if (this.keys.hasOwnProperty(iter732)) { + iter732 = this.keys[iter732]; + output.writeString(iter732); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3734 = input.readMapBegin(); + const _size733 = _rtmp3734.size || 0; + for (let _i735 = 0; _i735 < _size733; ++_i735) { + let key736 = null; + let val737 = null; + key736 = input.readString(); + val737 = []; + const _rtmp3739 = input.readSetBegin(); + const _size738 = _rtmp3739.size || 0; + for (let _i740 = 0; _i740 < _size738; ++_i740) { + let elem741 = null; + elem741 = new data_ttypes.TObject(); + elem741.read(input); + val737.push(elem741); + } + input.readSetEnd(); + this.success[key736] = val737; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter749 in this.keys) { + if (this.keys.hasOwnProperty(iter749)) { + iter749 = this.keys[iter749]; + output.writeString(iter749); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3751 = input.readMapBegin(); + const _size750 = _rtmp3751.size || 0; + for (let _i752 = 0; _i752 < _size750; ++_i752) { + let key753 = null; + let val754 = null; + key753 = input.readString(); + val754 = []; + const _rtmp3756 = input.readSetBegin(); + const _size755 = _rtmp3756.size || 0; + for (let _i757 = 0; _i757 < _size755; ++_i757) { + let elem758 = null; + elem758 = new data_ttypes.TObject(); + elem758.read(input); + val754.push(elem758); + } + input.readSetEnd(); + this.success[key753] = val754; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter766 in this.keys) { + if (this.keys.hasOwnProperty(iter766)) { + iter766 = this.keys[iter766]; + output.writeString(iter766); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3768 = input.readMapBegin(); + const _size767 = _rtmp3768.size || 0; + for (let _i769 = 0; _i769 < _size767; ++_i769) { + let key770 = null; + let val771 = null; + key770 = input.readString(); + val771 = []; + const _rtmp3773 = input.readSetBegin(); + const _size772 = _rtmp3773.size || 0; + for (let _i774 = 0; _i774 < _size772; ++_i774) { + let elem775 = null; + elem775 = new data_ttypes.TObject(); + elem775.read(input); + val771.push(elem775); + } + input.readSetEnd(); + this.success[key770] = val771; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter787 in this.keys) { + if (this.keys.hasOwnProperty(iter787)) { + iter787 = this.keys[iter787]; + output.writeString(iter787); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter788 in this.records) { + if (this.records.hasOwnProperty(iter788)) { + iter788 = this.records[iter788]; + output.writeI64(iter788); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3790 = input.readMapBegin(); + const _size789 = _rtmp3790.size || 0; + for (let _i791 = 0; _i791 < _size789; ++_i791) { + let key792 = null; + let val793 = null; + key792 = input.readI64(); + val793 = {}; + const _rtmp3795 = input.readMapBegin(); + const _size794 = _rtmp3795.size || 0; + for (let _i796 = 0; _i796 < _size794; ++_i796) { + let key797 = null; + let val798 = null; + key797 = input.readString(); + val798 = []; + const _rtmp3800 = input.readSetBegin(); + const _size799 = _rtmp3800.size || 0; + for (let _i801 = 0; _i801 < _size799; ++_i801) { + let elem802 = null; + elem802 = new data_ttypes.TObject(); + elem802.read(input); + val798.push(elem802); + } + input.readSetEnd(); + val793[key797] = val798; + } + input.readMapEnd(); + this.success[key792] = val793; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter812 in this.records) { + if (this.records.hasOwnProperty(iter812)) { + iter812 = this.records[iter812]; + output.writeI64(iter812); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3814 = input.readMapBegin(); + const _size813 = _rtmp3814.size || 0; + for (let _i815 = 0; _i815 < _size813; ++_i815) { + let key816 = null; + let val817 = null; + key816 = input.readI64(); + val817 = []; + const _rtmp3819 = input.readSetBegin(); + const _size818 = _rtmp3819.size || 0; + for (let _i820 = 0; _i820 < _size818; ++_i820) { + let elem821 = null; + elem821 = new data_ttypes.TObject(); + elem821.read(input); + val817.push(elem821); + } + input.readSetEnd(); + this.success[key816] = val817; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter829 in this.records) { + if (this.records.hasOwnProperty(iter829)) { + iter829 = this.records[iter829]; + output.writeI64(iter829); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3831 = input.readMapBegin(); + const _size830 = _rtmp3831.size || 0; + for (let _i832 = 0; _i832 < _size830; ++_i832) { + let key833 = null; + let val834 = null; + key833 = input.readI64(); + val834 = []; + const _rtmp3836 = input.readSetBegin(); + const _size835 = _rtmp3836.size || 0; + for (let _i837 = 0; _i837 < _size835; ++_i837) { + let elem838 = null; + elem838 = new data_ttypes.TObject(); + elem838.read(input); + val834.push(elem838); + } + input.readSetEnd(); + this.success[key833] = val834; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter846 in this.records) { + if (this.records.hasOwnProperty(iter846)) { + iter846 = this.records[iter846]; + output.writeI64(iter846); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3848 = input.readMapBegin(); + const _size847 = _rtmp3848.size || 0; + for (let _i849 = 0; _i849 < _size847; ++_i849) { + let key850 = null; + let val851 = null; + key850 = input.readI64(); + val851 = []; + const _rtmp3853 = input.readSetBegin(); + const _size852 = _rtmp3853.size || 0; + for (let _i854 = 0; _i854 < _size852; ++_i854) { + let elem855 = null; + elem855 = new data_ttypes.TObject(); + elem855.read(input); + val851.push(elem855); + } + input.readSetEnd(); + this.success[key850] = val851; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter867 in this.keys) { + if (this.keys.hasOwnProperty(iter867)) { + iter867 = this.keys[iter867]; + output.writeString(iter867); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter868 in this.records) { + if (this.records.hasOwnProperty(iter868)) { + iter868 = this.records[iter868]; + output.writeI64(iter868); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3870 = input.readMapBegin(); + const _size869 = _rtmp3870.size || 0; + for (let _i871 = 0; _i871 < _size869; ++_i871) { + let key872 = null; + let val873 = null; + key872 = input.readI64(); + val873 = {}; + const _rtmp3875 = input.readMapBegin(); + const _size874 = _rtmp3875.size || 0; + for (let _i876 = 0; _i876 < _size874; ++_i876) { + let key877 = null; + let val878 = null; + key877 = input.readString(); + val878 = []; + const _rtmp3880 = input.readSetBegin(); + const _size879 = _rtmp3880.size || 0; + for (let _i881 = 0; _i881 < _size879; ++_i881) { + let elem882 = null; + elem882 = new data_ttypes.TObject(); + elem882.read(input); + val878.push(elem882); + } + input.readSetEnd(); + val873[key877] = val878; + } + input.readMapEnd(); + this.success[key872] = val873; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter896 in this.keys) { + if (this.keys.hasOwnProperty(iter896)) { + iter896 = this.keys[iter896]; + output.writeString(iter896); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter897 in this.records) { + if (this.records.hasOwnProperty(iter897)) { + iter897 = this.records[iter897]; + output.writeI64(iter897); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3899 = input.readMapBegin(); + const _size898 = _rtmp3899.size || 0; + for (let _i900 = 0; _i900 < _size898; ++_i900) { + let key901 = null; + let val902 = null; + key901 = input.readI64(); + val902 = {}; + const _rtmp3904 = input.readMapBegin(); + const _size903 = _rtmp3904.size || 0; + for (let _i905 = 0; _i905 < _size903; ++_i905) { + let key906 = null; + let val907 = null; + key906 = input.readString(); + val907 = []; + const _rtmp3909 = input.readSetBegin(); + const _size908 = _rtmp3909.size || 0; + for (let _i910 = 0; _i910 < _size908; ++_i910) { + let elem911 = null; + elem911 = new data_ttypes.TObject(); + elem911.read(input); + val907.push(elem911); + } + input.readSetEnd(); + val902[key906] = val907; + } + input.readMapEnd(); + this.success[key901] = val902; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectCriteria_args = class { + constructor(args) { + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteria_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3918 = input.readMapBegin(); + const _size917 = _rtmp3918.size || 0; + for (let _i919 = 0; _i919 < _size917; ++_i919) { + let key920 = null; + let val921 = null; + key920 = input.readI64(); + val921 = {}; + const _rtmp3923 = input.readMapBegin(); + const _size922 = _rtmp3923.size || 0; + for (let _i924 = 0; _i924 < _size922; ++_i924) { + let key925 = null; + let val926 = null; + key925 = input.readString(); + val926 = []; + const _rtmp3928 = input.readSetBegin(); + const _size927 = _rtmp3928.size || 0; + for (let _i929 = 0; _i929 < _size927; ++_i929) { + let elem930 = null; + elem930 = new data_ttypes.TObject(); + elem930.read(input); + val926.push(elem930); + } + input.readSetEnd(); + val921[key925] = val926; + } + input.readMapEnd(); + this.success[key920] = val921; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectCcl_args = class { + constructor(args) { + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCcl_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3937 = input.readMapBegin(); + const _size936 = _rtmp3937.size || 0; + for (let _i938 = 0; _i938 < _size936; ++_i938) { + let key939 = null; + let val940 = null; + key939 = input.readI64(); + val940 = {}; + const _rtmp3942 = input.readMapBegin(); + const _size941 = _rtmp3942.size || 0; + for (let _i943 = 0; _i943 < _size941; ++_i943) { + let key944 = null; + let val945 = null; + key944 = input.readString(); + val945 = []; + const _rtmp3947 = input.readSetBegin(); + const _size946 = _rtmp3947.size || 0; + for (let _i948 = 0; _i948 < _size946; ++_i948) { + let elem949 = null; + elem949 = new data_ttypes.TObject(); + elem949.read(input); + val945.push(elem949); + } + input.readSetEnd(); + val940[key944] = val945; + } + input.readMapEnd(); + this.success[key939] = val940; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectCriteriaTime_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteriaTime_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3956 = input.readMapBegin(); + const _size955 = _rtmp3956.size || 0; + for (let _i957 = 0; _i957 < _size955; ++_i957) { + let key958 = null; + let val959 = null; + key958 = input.readI64(); + val959 = {}; + const _rtmp3961 = input.readMapBegin(); + const _size960 = _rtmp3961.size || 0; + for (let _i962 = 0; _i962 < _size960; ++_i962) { + let key963 = null; + let val964 = null; + key963 = input.readString(); + val964 = []; + const _rtmp3966 = input.readSetBegin(); + const _size965 = _rtmp3966.size || 0; + for (let _i967 = 0; _i967 < _size965; ++_i967) { + let elem968 = null; + elem968 = new data_ttypes.TObject(); + elem968.read(input); + val964.push(elem968); + } + input.readSetEnd(); + val959[key963] = val964; + } + input.readMapEnd(); + this.success[key958] = val959; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectCriteriaTimestr_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteriaTimestr_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3975 = input.readMapBegin(); + const _size974 = _rtmp3975.size || 0; + for (let _i976 = 0; _i976 < _size974; ++_i976) { + let key977 = null; + let val978 = null; + key977 = input.readI64(); + val978 = {}; + const _rtmp3980 = input.readMapBegin(); + const _size979 = _rtmp3980.size || 0; + for (let _i981 = 0; _i981 < _size979; ++_i981) { + let key982 = null; + let val983 = null; + key982 = input.readString(); + val983 = []; + const _rtmp3985 = input.readSetBegin(); + const _size984 = _rtmp3985.size || 0; + for (let _i986 = 0; _i986 < _size984; ++_i986) { + let elem987 = null; + elem987 = new data_ttypes.TObject(); + elem987.read(input); + val983.push(elem987); + } + input.readSetEnd(); + val978[key982] = val983; + } + input.readMapEnd(); + this.success[key977] = val978; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectCclTime_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCclTime_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3994 = input.readMapBegin(); + const _size993 = _rtmp3994.size || 0; + for (let _i995 = 0; _i995 < _size993; ++_i995) { + let key996 = null; + let val997 = null; + key996 = input.readI64(); + val997 = {}; + const _rtmp3999 = input.readMapBegin(); + const _size998 = _rtmp3999.size || 0; + for (let _i1000 = 0; _i1000 < _size998; ++_i1000) { + let key1001 = null; + let val1002 = null; + key1001 = input.readString(); + val1002 = []; + const _rtmp31004 = input.readSetBegin(); + const _size1003 = _rtmp31004.size || 0; + for (let _i1005 = 0; _i1005 < _size1003; ++_i1005) { + let elem1006 = null; + elem1006 = new data_ttypes.TObject(); + elem1006.read(input); + val1002.push(elem1006); + } + input.readSetEnd(); + val997[key1001] = val1002; + } + input.readMapEnd(); + this.success[key996] = val997; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectCclTimestr_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCclTimestr_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31013 = input.readMapBegin(); + const _size1012 = _rtmp31013.size || 0; + for (let _i1014 = 0; _i1014 < _size1012; ++_i1014) { + let key1015 = null; + let val1016 = null; + key1015 = input.readI64(); + val1016 = {}; + const _rtmp31018 = input.readMapBegin(); + const _size1017 = _rtmp31018.size || 0; + for (let _i1019 = 0; _i1019 < _size1017; ++_i1019) { + let key1020 = null; + let val1021 = null; + key1020 = input.readString(); + val1021 = []; + const _rtmp31023 = input.readSetBegin(); + const _size1022 = _rtmp31023.size || 0; + for (let _i1024 = 0; _i1024 < _size1022; ++_i1024) { + let elem1025 = null; + elem1025 = new data_ttypes.TObject(); + elem1025.read(input); + val1021.push(elem1025); + } + input.readSetEnd(); + val1016[key1020] = val1021; + } + input.readMapEnd(); + this.success[key1015] = val1016; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31032 = input.readMapBegin(); + const _size1031 = _rtmp31032.size || 0; + for (let _i1033 = 0; _i1033 < _size1031; ++_i1033) { + let key1034 = null; + let val1035 = null; + key1034 = input.readI64(); + val1035 = []; + const _rtmp31037 = input.readSetBegin(); + const _size1036 = _rtmp31037.size || 0; + for (let _i1038 = 0; _i1038 < _size1036; ++_i1038) { + let elem1039 = null; + elem1039 = new data_ttypes.TObject(); + elem1039.read(input); + val1035.push(elem1039); + } + input.readSetEnd(); + this.success[key1034] = val1035; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31044 = input.readMapBegin(); + const _size1043 = _rtmp31044.size || 0; + for (let _i1045 = 0; _i1045 < _size1043; ++_i1045) { + let key1046 = null; + let val1047 = null; + key1046 = input.readI64(); + val1047 = []; + const _rtmp31049 = input.readSetBegin(); + const _size1048 = _rtmp31049.size || 0; + for (let _i1050 = 0; _i1050 < _size1048; ++_i1050) { + let elem1051 = null; + elem1051 = new data_ttypes.TObject(); + elem1051.read(input); + val1047.push(elem1051); + } + input.readSetEnd(); + this.success[key1046] = val1047; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31056 = input.readMapBegin(); + const _size1055 = _rtmp31056.size || 0; + for (let _i1057 = 0; _i1057 < _size1055; ++_i1057) { + let key1058 = null; + let val1059 = null; + key1058 = input.readI64(); + val1059 = []; + const _rtmp31061 = input.readSetBegin(); + const _size1060 = _rtmp31061.size || 0; + for (let _i1062 = 0; _i1062 < _size1060; ++_i1062) { + let elem1063 = null; + elem1063 = new data_ttypes.TObject(); + elem1063.read(input); + val1059.push(elem1063); + } + input.readSetEnd(); + this.success[key1058] = val1059; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31068 = input.readMapBegin(); + const _size1067 = _rtmp31068.size || 0; + for (let _i1069 = 0; _i1069 < _size1067; ++_i1069) { + let key1070 = null; + let val1071 = null; + key1070 = input.readI64(); + val1071 = []; + const _rtmp31073 = input.readSetBegin(); + const _size1072 = _rtmp31073.size || 0; + for (let _i1074 = 0; _i1074 < _size1072; ++_i1074) { + let elem1075 = null; + elem1075 = new data_ttypes.TObject(); + elem1075.read(input); + val1071.push(elem1075); + } + input.readSetEnd(); + this.success[key1070] = val1071; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31080 = input.readMapBegin(); + const _size1079 = _rtmp31080.size || 0; + for (let _i1081 = 0; _i1081 < _size1079; ++_i1081) { + let key1082 = null; + let val1083 = null; + key1082 = input.readI64(); + val1083 = []; + const _rtmp31085 = input.readSetBegin(); + const _size1084 = _rtmp31085.size || 0; + for (let _i1086 = 0; _i1086 < _size1084; ++_i1086) { + let elem1087 = null; + elem1087 = new data_ttypes.TObject(); + elem1087.read(input); + val1083.push(elem1087); + } + input.readSetEnd(); + this.success[key1082] = val1083; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31092 = input.readMapBegin(); + const _size1091 = _rtmp31092.size || 0; + for (let _i1093 = 0; _i1093 < _size1091; ++_i1093) { + let key1094 = null; + let val1095 = null; + key1094 = input.readI64(); + val1095 = []; + const _rtmp31097 = input.readSetBegin(); + const _size1096 = _rtmp31097.size || 0; + for (let _i1098 = 0; _i1098 < _size1096; ++_i1098) { + let elem1099 = null; + elem1099 = new data_ttypes.TObject(); + elem1099.read(input); + val1095.push(elem1099); + } + input.readSetEnd(); + this.success[key1094] = val1095; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCriteria_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteria_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1107 in this.keys) { + if (this.keys.hasOwnProperty(iter1107)) { + iter1107 = this.keys[iter1107]; + output.writeString(iter1107); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31109 = input.readMapBegin(); + const _size1108 = _rtmp31109.size || 0; + for (let _i1110 = 0; _i1110 < _size1108; ++_i1110) { + let key1111 = null; + let val1112 = null; + key1111 = input.readI64(); + val1112 = {}; + const _rtmp31114 = input.readMapBegin(); + const _size1113 = _rtmp31114.size || 0; + for (let _i1115 = 0; _i1115 < _size1113; ++_i1115) { + let key1116 = null; + let val1117 = null; + key1116 = input.readString(); + val1117 = []; + const _rtmp31119 = input.readSetBegin(); + const _size1118 = _rtmp31119.size || 0; + for (let _i1120 = 0; _i1120 < _size1118; ++_i1120) { + let elem1121 = null; + elem1121 = new data_ttypes.TObject(); + elem1121.read(input); + val1117.push(elem1121); + } + input.readSetEnd(); + val1112[key1116] = val1117; + } + input.readMapEnd(); + this.success[key1111] = val1112; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCcl_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCcl_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1131 in this.keys) { + if (this.keys.hasOwnProperty(iter1131)) { + iter1131 = this.keys[iter1131]; + output.writeString(iter1131); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31133 = input.readMapBegin(); + const _size1132 = _rtmp31133.size || 0; + for (let _i1134 = 0; _i1134 < _size1132; ++_i1134) { + let key1135 = null; + let val1136 = null; + key1135 = input.readI64(); + val1136 = {}; + const _rtmp31138 = input.readMapBegin(); + const _size1137 = _rtmp31138.size || 0; + for (let _i1139 = 0; _i1139 < _size1137; ++_i1139) { + let key1140 = null; + let val1141 = null; + key1140 = input.readString(); + val1141 = []; + const _rtmp31143 = input.readSetBegin(); + const _size1142 = _rtmp31143.size || 0; + for (let _i1144 = 0; _i1144 < _size1142; ++_i1144) { + let elem1145 = null; + elem1145 = new data_ttypes.TObject(); + elem1145.read(input); + val1141.push(elem1145); + } + input.readSetEnd(); + val1136[key1140] = val1141; + } + input.readMapEnd(); + this.success[key1135] = val1136; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCriteriaTime_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteriaTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1155 in this.keys) { + if (this.keys.hasOwnProperty(iter1155)) { + iter1155 = this.keys[iter1155]; + output.writeString(iter1155); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31157 = input.readMapBegin(); + const _size1156 = _rtmp31157.size || 0; + for (let _i1158 = 0; _i1158 < _size1156; ++_i1158) { + let key1159 = null; + let val1160 = null; + key1159 = input.readI64(); + val1160 = {}; + const _rtmp31162 = input.readMapBegin(); + const _size1161 = _rtmp31162.size || 0; + for (let _i1163 = 0; _i1163 < _size1161; ++_i1163) { + let key1164 = null; + let val1165 = null; + key1164 = input.readString(); + val1165 = []; + const _rtmp31167 = input.readSetBegin(); + const _size1166 = _rtmp31167.size || 0; + for (let _i1168 = 0; _i1168 < _size1166; ++_i1168) { + let elem1169 = null; + elem1169 = new data_ttypes.TObject(); + elem1169.read(input); + val1165.push(elem1169); + } + input.readSetEnd(); + val1160[key1164] = val1165; + } + input.readMapEnd(); + this.success[key1159] = val1160; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCriteriaTimestr_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteriaTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1179 in this.keys) { + if (this.keys.hasOwnProperty(iter1179)) { + iter1179 = this.keys[iter1179]; + output.writeString(iter1179); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31181 = input.readMapBegin(); + const _size1180 = _rtmp31181.size || 0; + for (let _i1182 = 0; _i1182 < _size1180; ++_i1182) { + let key1183 = null; + let val1184 = null; + key1183 = input.readI64(); + val1184 = {}; + const _rtmp31186 = input.readMapBegin(); + const _size1185 = _rtmp31186.size || 0; + for (let _i1187 = 0; _i1187 < _size1185; ++_i1187) { + let key1188 = null; + let val1189 = null; + key1188 = input.readString(); + val1189 = []; + const _rtmp31191 = input.readSetBegin(); + const _size1190 = _rtmp31191.size || 0; + for (let _i1192 = 0; _i1192 < _size1190; ++_i1192) { + let elem1193 = null; + elem1193 = new data_ttypes.TObject(); + elem1193.read(input); + val1189.push(elem1193); + } + input.readSetEnd(); + val1184[key1188] = val1189; + } + input.readMapEnd(); + this.success[key1183] = val1184; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCclTime_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCclTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1203 in this.keys) { + if (this.keys.hasOwnProperty(iter1203)) { + iter1203 = this.keys[iter1203]; + output.writeString(iter1203); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31205 = input.readMapBegin(); + const _size1204 = _rtmp31205.size || 0; + for (let _i1206 = 0; _i1206 < _size1204; ++_i1206) { + let key1207 = null; + let val1208 = null; + key1207 = input.readI64(); + val1208 = {}; + const _rtmp31210 = input.readMapBegin(); + const _size1209 = _rtmp31210.size || 0; + for (let _i1211 = 0; _i1211 < _size1209; ++_i1211) { + let key1212 = null; + let val1213 = null; + key1212 = input.readString(); + val1213 = []; + const _rtmp31215 = input.readSetBegin(); + const _size1214 = _rtmp31215.size || 0; + for (let _i1216 = 0; _i1216 < _size1214; ++_i1216) { + let elem1217 = null; + elem1217 = new data_ttypes.TObject(); + elem1217.read(input); + val1213.push(elem1217); + } + input.readSetEnd(); + val1208[key1212] = val1213; + } + input.readMapEnd(); + this.success[key1207] = val1208; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCclTimestr_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCclTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1227 in this.keys) { + if (this.keys.hasOwnProperty(iter1227)) { + iter1227 = this.keys[iter1227]; + output.writeString(iter1227); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_selectKeysCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31229 = input.readMapBegin(); + const _size1228 = _rtmp31229.size || 0; + for (let _i1230 = 0; _i1230 < _size1228; ++_i1230) { + let key1231 = null; + let val1232 = null; + key1231 = input.readI64(); + val1232 = {}; + const _rtmp31234 = input.readMapBegin(); + const _size1233 = _rtmp31234.size || 0; + for (let _i1235 = 0; _i1235 < _size1233; ++_i1235) { + let key1236 = null; + let val1237 = null; + key1236 = input.readString(); + val1237 = []; + const _rtmp31239 = input.readSetBegin(); + const _size1238 = _rtmp31239.size || 0; + for (let _i1240 = 0; _i1240 < _size1238; ++_i1240) { + let elem1241 = null; + elem1241 = new data_ttypes.TObject(); + elem1241.read(input); + val1237.push(elem1241); + } + input.readSetEnd(); + val1232[key1236] = val1237; + } + input.readMapEnd(); + this.success[key1231] = val1232; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1251 in this.keys) { + if (this.keys.hasOwnProperty(iter1251)) { + iter1251 = this.keys[iter1251]; + output.writeString(iter1251); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31253 = input.readMapBegin(); + const _size1252 = _rtmp31253.size || 0; + for (let _i1254 = 0; _i1254 < _size1252; ++_i1254) { + let key1255 = null; + let val1256 = null; + key1255 = input.readString(); + val1256 = new data_ttypes.TObject(); + val1256.read(input); + this.success[key1255] = val1256; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1263 in this.keys) { + if (this.keys.hasOwnProperty(iter1263)) { + iter1263 = this.keys[iter1263]; + output.writeString(iter1263); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31265 = input.readMapBegin(); + const _size1264 = _rtmp31265.size || 0; + for (let _i1266 = 0; _i1266 < _size1264; ++_i1266) { + let key1267 = null; + let val1268 = null; + key1267 = input.readString(); + val1268 = new data_ttypes.TObject(); + val1268.read(input); + this.success[key1267] = val1268; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1275 in this.keys) { + if (this.keys.hasOwnProperty(iter1275)) { + iter1275 = this.keys[iter1275]; + output.writeString(iter1275); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31277 = input.readMapBegin(); + const _size1276 = _rtmp31277.size || 0; + for (let _i1278 = 0; _i1278 < _size1276; ++_i1278) { + let key1279 = null; + let val1280 = null; + key1279 = input.readString(); + val1280 = new data_ttypes.TObject(); + val1280.read(input); + this.success[key1279] = val1280; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1291 in this.keys) { + if (this.keys.hasOwnProperty(iter1291)) { + iter1291 = this.keys[iter1291]; + output.writeString(iter1291); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1292 in this.records) { + if (this.records.hasOwnProperty(iter1292)) { + iter1292 = this.records[iter1292]; + output.writeI64(iter1292); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31294 = input.readMapBegin(); + const _size1293 = _rtmp31294.size || 0; + for (let _i1295 = 0; _i1295 < _size1293; ++_i1295) { + let key1296 = null; + let val1297 = null; + key1296 = input.readI64(); + val1297 = {}; + const _rtmp31299 = input.readMapBegin(); + const _size1298 = _rtmp31299.size || 0; + for (let _i1300 = 0; _i1300 < _size1298; ++_i1300) { + let key1301 = null; + let val1302 = null; + key1301 = input.readString(); + val1302 = new data_ttypes.TObject(); + val1302.read(input); + val1297[key1301] = val1302; + } + input.readMapEnd(); + this.success[key1296] = val1297; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1311 in this.records) { + if (this.records.hasOwnProperty(iter1311)) { + iter1311 = this.records[iter1311]; + output.writeI64(iter1311); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31313 = input.readMapBegin(); + const _size1312 = _rtmp31313.size || 0; + for (let _i1314 = 0; _i1314 < _size1312; ++_i1314) { + let key1315 = null; + let val1316 = null; + key1315 = input.readI64(); + val1316 = new data_ttypes.TObject(); + val1316.read(input); + this.success[key1315] = val1316; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1323 in this.records) { + if (this.records.hasOwnProperty(iter1323)) { + iter1323 = this.records[iter1323]; + output.writeI64(iter1323); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31325 = input.readMapBegin(); + const _size1324 = _rtmp31325.size || 0; + for (let _i1326 = 0; _i1326 < _size1324; ++_i1326) { + let key1327 = null; + let val1328 = null; + key1327 = input.readI64(); + val1328 = new data_ttypes.TObject(); + val1328.read(input); + this.success[key1327] = val1328; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1335 in this.records) { + if (this.records.hasOwnProperty(iter1335)) { + iter1335 = this.records[iter1335]; + output.writeI64(iter1335); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31337 = input.readMapBegin(); + const _size1336 = _rtmp31337.size || 0; + for (let _i1338 = 0; _i1338 < _size1336; ++_i1338) { + let key1339 = null; + let val1340 = null; + key1339 = input.readI64(); + val1340 = new data_ttypes.TObject(); + val1340.read(input); + this.success[key1339] = val1340; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1351 in this.keys) { + if (this.keys.hasOwnProperty(iter1351)) { + iter1351 = this.keys[iter1351]; + output.writeString(iter1351); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1352 in this.records) { + if (this.records.hasOwnProperty(iter1352)) { + iter1352 = this.records[iter1352]; + output.writeI64(iter1352); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31354 = input.readMapBegin(); + const _size1353 = _rtmp31354.size || 0; + for (let _i1355 = 0; _i1355 < _size1353; ++_i1355) { + let key1356 = null; + let val1357 = null; + key1356 = input.readI64(); + val1357 = {}; + const _rtmp31359 = input.readMapBegin(); + const _size1358 = _rtmp31359.size || 0; + for (let _i1360 = 0; _i1360 < _size1358; ++_i1360) { + let key1361 = null; + let val1362 = null; + key1361 = input.readString(); + val1362 = new data_ttypes.TObject(); + val1362.read(input); + val1357[key1361] = val1362; + } + input.readMapEnd(); + this.success[key1356] = val1357; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1375 in this.keys) { + if (this.keys.hasOwnProperty(iter1375)) { + iter1375 = this.keys[iter1375]; + output.writeString(iter1375); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1376 in this.records) { + if (this.records.hasOwnProperty(iter1376)) { + iter1376 = this.records[iter1376]; + output.writeI64(iter1376); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31378 = input.readMapBegin(); + const _size1377 = _rtmp31378.size || 0; + for (let _i1379 = 0; _i1379 < _size1377; ++_i1379) { + let key1380 = null; + let val1381 = null; + key1380 = input.readI64(); + val1381 = {}; + const _rtmp31383 = input.readMapBegin(); + const _size1382 = _rtmp31383.size || 0; + for (let _i1384 = 0; _i1384 < _size1382; ++_i1384) { + let key1385 = null; + let val1386 = null; + key1385 = input.readString(); + val1386 = new data_ttypes.TObject(); + val1386.read(input); + val1381[key1385] = val1386; + } + input.readMapEnd(); + this.success[key1380] = val1381; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31392 = input.readMapBegin(); + const _size1391 = _rtmp31392.size || 0; + for (let _i1393 = 0; _i1393 < _size1391; ++_i1393) { + let key1394 = null; + let val1395 = null; + key1394 = input.readI64(); + val1395 = new data_ttypes.TObject(); + val1395.read(input); + this.success[key1394] = val1395; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getCriteria_args = class { + constructor(args) { + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteria_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31399 = input.readMapBegin(); + const _size1398 = _rtmp31399.size || 0; + for (let _i1400 = 0; _i1400 < _size1398; ++_i1400) { + let key1401 = null; + let val1402 = null; + key1401 = input.readI64(); + val1402 = {}; + const _rtmp31404 = input.readMapBegin(); + const _size1403 = _rtmp31404.size || 0; + for (let _i1405 = 0; _i1405 < _size1403; ++_i1405) { + let key1406 = null; + let val1407 = null; + key1406 = input.readString(); + val1407 = new data_ttypes.TObject(); + val1407.read(input); + val1402[key1406] = val1407; + } + input.readMapEnd(); + this.success[key1401] = val1402; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getCcl_args = class { + constructor(args) { + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getCcl_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31413 = input.readMapBegin(); + const _size1412 = _rtmp31413.size || 0; + for (let _i1414 = 0; _i1414 < _size1412; ++_i1414) { + let key1415 = null; + let val1416 = null; + key1415 = input.readI64(); + val1416 = {}; + const _rtmp31418 = input.readMapBegin(); + const _size1417 = _rtmp31418.size || 0; + for (let _i1419 = 0; _i1419 < _size1417; ++_i1419) { + let key1420 = null; + let val1421 = null; + key1420 = input.readString(); + val1421 = new data_ttypes.TObject(); + val1421.read(input); + val1416[key1420] = val1421; + } + input.readMapEnd(); + this.success[key1415] = val1416; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getCriteriaTime_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteriaTime_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31427 = input.readMapBegin(); + const _size1426 = _rtmp31427.size || 0; + for (let _i1428 = 0; _i1428 < _size1426; ++_i1428) { + let key1429 = null; + let val1430 = null; + key1429 = input.readI64(); + val1430 = {}; + const _rtmp31432 = input.readMapBegin(); + const _size1431 = _rtmp31432.size || 0; + for (let _i1433 = 0; _i1433 < _size1431; ++_i1433) { + let key1434 = null; + let val1435 = null; + key1434 = input.readString(); + val1435 = new data_ttypes.TObject(); + val1435.read(input); + val1430[key1434] = val1435; + } + input.readMapEnd(); + this.success[key1429] = val1430; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getCriteriaTimestr_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteriaTimestr_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31441 = input.readMapBegin(); + const _size1440 = _rtmp31441.size || 0; + for (let _i1442 = 0; _i1442 < _size1440; ++_i1442) { + let key1443 = null; + let val1444 = null; + key1443 = input.readI64(); + val1444 = {}; + const _rtmp31446 = input.readMapBegin(); + const _size1445 = _rtmp31446.size || 0; + for (let _i1447 = 0; _i1447 < _size1445; ++_i1447) { + let key1448 = null; + let val1449 = null; + key1448 = input.readString(); + val1449 = new data_ttypes.TObject(); + val1449.read(input); + val1444[key1448] = val1449; + } + input.readMapEnd(); + this.success[key1443] = val1444; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getCclTime_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getCclTime_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31455 = input.readMapBegin(); + const _size1454 = _rtmp31455.size || 0; + for (let _i1456 = 0; _i1456 < _size1454; ++_i1456) { + let key1457 = null; + let val1458 = null; + key1457 = input.readI64(); + val1458 = {}; + const _rtmp31460 = input.readMapBegin(); + const _size1459 = _rtmp31460.size || 0; + for (let _i1461 = 0; _i1461 < _size1459; ++_i1461) { + let key1462 = null; + let val1463 = null; + key1462 = input.readString(); + val1463 = new data_ttypes.TObject(); + val1463.read(input); + val1458[key1462] = val1463; + } + input.readMapEnd(); + this.success[key1457] = val1458; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getCclTimestr_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getCclTimestr_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31469 = input.readMapBegin(); + const _size1468 = _rtmp31469.size || 0; + for (let _i1470 = 0; _i1470 < _size1468; ++_i1470) { + let key1471 = null; + let val1472 = null; + key1471 = input.readI64(); + val1472 = {}; + const _rtmp31474 = input.readMapBegin(); + const _size1473 = _rtmp31474.size || 0; + for (let _i1475 = 0; _i1475 < _size1473; ++_i1475) { + let key1476 = null; + let val1477 = null; + key1476 = input.readString(); + val1477 = new data_ttypes.TObject(); + val1477.read(input); + val1472[key1476] = val1477; + } + input.readMapEnd(); + this.success[key1471] = val1472; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31483 = input.readMapBegin(); + const _size1482 = _rtmp31483.size || 0; + for (let _i1484 = 0; _i1484 < _size1482; ++_i1484) { + let key1485 = null; + let val1486 = null; + key1485 = input.readI64(); + val1486 = new data_ttypes.TObject(); + val1486.read(input); + this.success[key1485] = val1486; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31490 = input.readMapBegin(); + const _size1489 = _rtmp31490.size || 0; + for (let _i1491 = 0; _i1491 < _size1489; ++_i1491) { + let key1492 = null; + let val1493 = null; + key1492 = input.readI64(); + val1493 = new data_ttypes.TObject(); + val1493.read(input); + this.success[key1492] = val1493; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31497 = input.readMapBegin(); + const _size1496 = _rtmp31497.size || 0; + for (let _i1498 = 0; _i1498 < _size1496; ++_i1498) { + let key1499 = null; + let val1500 = null; + key1499 = input.readI64(); + val1500 = new data_ttypes.TObject(); + val1500.read(input); + this.success[key1499] = val1500; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31504 = input.readMapBegin(); + const _size1503 = _rtmp31504.size || 0; + for (let _i1505 = 0; _i1505 < _size1503; ++_i1505) { + let key1506 = null; + let val1507 = null; + key1506 = input.readI64(); + val1507 = new data_ttypes.TObject(); + val1507.read(input); + this.success[key1506] = val1507; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31511 = input.readMapBegin(); + const _size1510 = _rtmp31511.size || 0; + for (let _i1512 = 0; _i1512 < _size1510; ++_i1512) { + let key1513 = null; + let val1514 = null; + key1513 = input.readI64(); + val1514 = new data_ttypes.TObject(); + val1514.read(input); + this.success[key1513] = val1514; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysCriteria_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteria_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1521 in this.keys) { + if (this.keys.hasOwnProperty(iter1521)) { + iter1521 = this.keys[iter1521]; + output.writeString(iter1521); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31523 = input.readMapBegin(); + const _size1522 = _rtmp31523.size || 0; + for (let _i1524 = 0; _i1524 < _size1522; ++_i1524) { + let key1525 = null; + let val1526 = null; + key1525 = input.readI64(); + val1526 = {}; + const _rtmp31528 = input.readMapBegin(); + const _size1527 = _rtmp31528.size || 0; + for (let _i1529 = 0; _i1529 < _size1527; ++_i1529) { + let key1530 = null; + let val1531 = null; + key1530 = input.readString(); + val1531 = new data_ttypes.TObject(); + val1531.read(input); + val1526[key1530] = val1531; + } + input.readMapEnd(); + this.success[key1525] = val1526; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysCcl_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCcl_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1540 in this.keys) { + if (this.keys.hasOwnProperty(iter1540)) { + iter1540 = this.keys[iter1540]; + output.writeString(iter1540); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31542 = input.readMapBegin(); + const _size1541 = _rtmp31542.size || 0; + for (let _i1543 = 0; _i1543 < _size1541; ++_i1543) { + let key1544 = null; + let val1545 = null; + key1544 = input.readI64(); + val1545 = {}; + const _rtmp31547 = input.readMapBegin(); + const _size1546 = _rtmp31547.size || 0; + for (let _i1548 = 0; _i1548 < _size1546; ++_i1548) { + let key1549 = null; + let val1550 = null; + key1549 = input.readString(); + val1550 = new data_ttypes.TObject(); + val1550.read(input); + val1545[key1549] = val1550; + } + input.readMapEnd(); + this.success[key1544] = val1545; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysCriteriaTime_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteriaTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1559 in this.keys) { + if (this.keys.hasOwnProperty(iter1559)) { + iter1559 = this.keys[iter1559]; + output.writeString(iter1559); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31561 = input.readMapBegin(); + const _size1560 = _rtmp31561.size || 0; + for (let _i1562 = 0; _i1562 < _size1560; ++_i1562) { + let key1563 = null; + let val1564 = null; + key1563 = input.readI64(); + val1564 = {}; + const _rtmp31566 = input.readMapBegin(); + const _size1565 = _rtmp31566.size || 0; + for (let _i1567 = 0; _i1567 < _size1565; ++_i1567) { + let key1568 = null; + let val1569 = null; + key1568 = input.readString(); + val1569 = new data_ttypes.TObject(); + val1569.read(input); + val1564[key1568] = val1569; + } + input.readMapEnd(); + this.success[key1563] = val1564; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysCriteriaTimestr_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteriaTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1578 in this.keys) { + if (this.keys.hasOwnProperty(iter1578)) { + iter1578 = this.keys[iter1578]; + output.writeString(iter1578); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31580 = input.readMapBegin(); + const _size1579 = _rtmp31580.size || 0; + for (let _i1581 = 0; _i1581 < _size1579; ++_i1581) { + let key1582 = null; + let val1583 = null; + key1582 = input.readI64(); + val1583 = {}; + const _rtmp31585 = input.readMapBegin(); + const _size1584 = _rtmp31585.size || 0; + for (let _i1586 = 0; _i1586 < _size1584; ++_i1586) { + let key1587 = null; + let val1588 = null; + key1587 = input.readString(); + val1588 = new data_ttypes.TObject(); + val1588.read(input); + val1583[key1587] = val1588; + } + input.readMapEnd(); + this.success[key1582] = val1583; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysCclTime_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCclTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1597 in this.keys) { + if (this.keys.hasOwnProperty(iter1597)) { + iter1597 = this.keys[iter1597]; + output.writeString(iter1597); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31599 = input.readMapBegin(); + const _size1598 = _rtmp31599.size || 0; + for (let _i1600 = 0; _i1600 < _size1598; ++_i1600) { + let key1601 = null; + let val1602 = null; + key1601 = input.readI64(); + val1602 = {}; + const _rtmp31604 = input.readMapBegin(); + const _size1603 = _rtmp31604.size || 0; + for (let _i1605 = 0; _i1605 < _size1603; ++_i1605) { + let key1606 = null; + let val1607 = null; + key1606 = input.readString(); + val1607 = new data_ttypes.TObject(); + val1607.read(input); + val1602[key1606] = val1607; + } + input.readMapEnd(); + this.success[key1601] = val1602; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getKeysCclTimestr_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCclTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1616 in this.keys) { + if (this.keys.hasOwnProperty(iter1616)) { + iter1616 = this.keys[iter1616]; + output.writeString(iter1616); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getKeysCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31618 = input.readMapBegin(); + const _size1617 = _rtmp31618.size || 0; + for (let _i1619 = 0; _i1619 < _size1617; ++_i1619) { + let key1620 = null; + let val1621 = null; + key1620 = input.readI64(); + val1621 = {}; + const _rtmp31623 = input.readMapBegin(); + const _size1622 = _rtmp31623.size || 0; + for (let _i1624 = 0; _i1624 < _size1622; ++_i1624) { + let key1625 = null; + let val1626 = null; + key1625 = input.readString(); + val1626 = new data_ttypes.TObject(); + val1626.read(input); + val1621[key1625] = val1626; + } + input.readMapEnd(); + this.success[key1620] = val1621; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_verifyKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_verifyKeyValueRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_verifyKeyValueRecordTime_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_verifyKeyValueRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_verifyKeyValueRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_verifyKeyValueRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_jsonifyRecords_args = class { + constructor(args) { + this.records = null; + this.identifier = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.identifier !== undefined && args.identifier !== null) { + this.identifier = args.identifier; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1635 in this.records) { + if (this.records.hasOwnProperty(iter1635)) { + iter1635 = this.records[iter1635]; + output.writeI64(iter1635); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.identifier !== null && this.identifier !== undefined) { + output.writeFieldBegin('identifier', Thrift.Type.BOOL, 2); + output.writeBool(this.identifier); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_jsonifyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_jsonifyRecordsTime_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.identifier = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.identifier !== undefined && args.identifier !== null) { + this.identifier = args.identifier; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecordsTime_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1640 in this.records) { + if (this.records.hasOwnProperty(iter1640)) { + iter1640 = this.records[iter1640]; + output.writeI64(iter1640); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.identifier !== null && this.identifier !== undefined) { + output.writeFieldBegin('identifier', Thrift.Type.BOOL, 3); + output.writeBool(this.identifier); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_jsonifyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_jsonifyRecordsTimestr_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.identifier = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.identifier !== undefined && args.identifier !== null) { + this.identifier = args.identifier; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecordsTimestr_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1645 in this.records) { + if (this.records.hasOwnProperty(iter1645)) { + iter1645 = this.records[iter1645]; + output.writeI64(iter1645); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.identifier !== null && this.identifier !== undefined) { + output.writeFieldBegin('identifier', Thrift.Type.BOOL, 3); + output.writeBool(this.identifier); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_jsonifyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findCriteria_args = class { + constructor(args) { + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findCriteria_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31647 = input.readSetBegin(); + const _size1646 = _rtmp31647.size || 0; + for (let _i1648 = 0; _i1648 < _size1646; ++_i1648) { + let elem1649 = null; + elem1649 = input.readI64(); + this.success.push(elem1649); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findCcl_args = class { + constructor(args) { + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findCcl_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31652 = input.readSetBegin(); + const _size1651 = _rtmp31652.size || 0; + for (let _i1653 = 0; _i1653 < _size1651; ++_i1653) { + let elem1654 = null; + elem1654 = input.readI64(); + this.success.push(elem1654); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorValues_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValues_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.I32, 2); + output.writeI32(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1660 in this.values) { + if (this.values.hasOwnProperty(iter1660)) { + iter1660 = this.values[iter1660]; + iter1660.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorValues_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31662 = input.readSetBegin(); + const _size1661 = _rtmp31662.size || 0; + for (let _i1663 = 0; _i1663 < _size1661; ++_i1663) { + let elem1664 = null; + elem1664 = input.readI64(); + this.success.push(elem1664); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorValuesTime_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValuesTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.I32, 2); + output.writeI32(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1670 in this.values) { + if (this.values.hasOwnProperty(iter1670)) { + iter1670 = this.values[iter1670]; + iter1670.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorValuesTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31672 = input.readSetBegin(); + const _size1671 = _rtmp31672.size || 0; + for (let _i1673 = 0; _i1673 < _size1671; ++_i1673) { + let elem1674 = null; + elem1674 = input.readI64(); + this.success.push(elem1674); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorValuesTimestr_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValuesTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.I32, 2); + output.writeI32(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1680 in this.values) { + if (this.values.hasOwnProperty(iter1680)) { + iter1680 = this.values[iter1680]; + iter1680.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorValuesTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31682 = input.readSetBegin(); + const _size1681 = _rtmp31682.size || 0; + for (let _i1683 = 0; _i1683 < _size1681; ++_i1683) { + let elem1684 = null; + elem1684 = input.readI64(); + this.success.push(elem1684); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorstrValues_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValues_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.STRING, 2); + output.writeString(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1690 in this.values) { + if (this.values.hasOwnProperty(iter1690)) { + iter1690 = this.values[iter1690]; + iter1690.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorstrValues_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31692 = input.readSetBegin(); + const _size1691 = _rtmp31692.size || 0; + for (let _i1693 = 0; _i1693 < _size1691; ++_i1693) { + let elem1694 = null; + elem1694 = input.readI64(); + this.success.push(elem1694); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorstrValuesTime_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.STRING, 2); + output.writeString(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1700 in this.values) { + if (this.values.hasOwnProperty(iter1700)) { + iter1700 = this.values[iter1700]; + iter1700.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorstrValuesTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31702 = input.readSetBegin(); + const _size1701 = _rtmp31702.size || 0; + for (let _i1703 = 0; _i1703 < _size1701; ++_i1703) { + let elem1704 = null; + elem1704 = input.readI64(); + this.success.push(elem1704); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorstrValuesTimestr_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.STRING, 2); + output.writeString(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1710 in this.values) { + if (this.values.hasOwnProperty(iter1710)) { + iter1710 = this.values[iter1710]; + iter1710.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findKeyOperatorstrValuesTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31712 = input.readSetBegin(); + const _size1711 = _rtmp31712.size || 0; + for (let _i1713 = 0; _i1713 < _size1711; ++_i1713) { + let elem1714 = null; + elem1714 = input.readI64(); + this.success.push(elem1714); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_search_args = class { + constructor(args) { + this.key = null; + this.query = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.query !== undefined && args.query !== null) { + this.query = args.query; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_search_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.query !== null && this.query !== undefined) { + output.writeFieldBegin('query', Thrift.Type.STRING, 2); + output.writeString(this.query); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_search_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31717 = input.readSetBegin(); + const _size1716 = _rtmp31717.size || 0; + for (let _i1718 = 0; _i1718 < _size1716; ++_i1718) { + let elem1719 = null; + elem1719 = input.readI64(); + this.success.push(elem1719); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1729 in this.keys) { + if (this.keys.hasOwnProperty(iter1729)) { + iter1729 = this.keys[iter1729]; + output.writeString(iter1729); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1730 in this.records) { + if (this.records.hasOwnProperty(iter1730)) { + iter1730 = this.records[iter1730]; + output.writeI64(iter1730); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordsTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1739 in this.keys) { + if (this.keys.hasOwnProperty(iter1739)) { + iter1739 = this.keys[iter1739]; + output.writeString(iter1739); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1740 in this.records) { + if (this.records.hasOwnProperty(iter1740)) { + iter1740 = this.records[iter1740]; + output.writeI64(iter1740); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordsTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1745 in this.keys) { + if (this.keys.hasOwnProperty(iter1745)) { + iter1745 = this.keys[iter1745]; + output.writeString(iter1745); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1750 in this.keys) { + if (this.keys.hasOwnProperty(iter1750)) { + iter1750 = this.keys[iter1750]; + output.writeString(iter1750); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeysRecordTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1755 in this.records) { + if (this.records.hasOwnProperty(iter1755)) { + iter1755 = this.records[iter1755]; + output.writeI64(iter1755); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordsTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1760 in this.records) { + if (this.records.hasOwnProperty(iter1760)) { + iter1760 = this.records[iter1760]; + output.writeI64(iter1760); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordsTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_revertKeyRecordTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_pingRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_pingRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1765 in this.records) { + if (this.records.hasOwnProperty(iter1765)) { + iter1765 = this.records[iter1765]; + output.writeI64(iter1765); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_pingRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31767 = input.readMapBegin(); + const _size1766 = _rtmp31767.size || 0; + for (let _i1768 = 0; _i1768 < _size1766; ++_i1768) { + let key1769 = null; + let val1770 = null; + key1769 = input.readI64(); + val1770 = input.readBool(); + this.success[key1769] = val1770; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_pingRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_pingRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_pingRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_verifyAndSwap_args = class { + constructor(args) { + this.key = null; + this.expected = null; + this.record = null; + this.replacement = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.expected !== undefined && args.expected !== null) { + this.expected = new data_ttypes.TObject(args.expected); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.replacement !== undefined && args.replacement !== null) { + this.replacement = new data_ttypes.TObject(args.replacement); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyAndSwap_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.expected !== null && this.expected !== undefined) { + output.writeFieldBegin('expected', Thrift.Type.STRUCT, 2); + this.expected.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.replacement !== null && this.replacement !== undefined) { + output.writeFieldBegin('replacement', Thrift.Type.STRUCT, 4); + this.replacement.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_verifyAndSwap_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_verifyOrSet_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyOrSet_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_verifyOrSet_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findOrAddKeyValue_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrAddKeyValue_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findOrAddKeyValue_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.DuplicateEntryException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.DuplicateEntryException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findOrInsertCriteriaJson_args = class { + constructor(args) { + this.criteria = null; + this.json = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrInsertCriteriaJson_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 2); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findOrInsertCriteriaJson_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.DuplicateEntryException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.DuplicateEntryException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_findOrInsertCclJson_args = class { + constructor(args) { + this.ccl = null; + this.json = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrInsertCclJson_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 2); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_findOrInsertCclJson_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.DuplicateEntryException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.DuplicateEntryException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1777 in this.records) { + if (this.records.hasOwnProperty(iter1777)) { + iter1777 = this.records[iter1777]; + output.writeI64(iter1777); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1782 in this.records) { + if (this.records.hasOwnProperty(iter1782)) { + iter1782 = this.records[iter1782]; + output.writeI64(iter1782); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1787 in this.records) { + if (this.records.hasOwnProperty(iter1787)) { + iter1787 = this.records[iter1787]; + output.writeI64(iter1787); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_sumKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1792 in this.records) { + if (this.records.hasOwnProperty(iter1792)) { + iter1792 = this.records[iter1792]; + output.writeI64(iter1792); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1797 in this.records) { + if (this.records.hasOwnProperty(iter1797)) { + iter1797 = this.records[iter1797]; + output.writeI64(iter1797); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1802 in this.records) { + if (this.records.hasOwnProperty(iter1802)) { + iter1802 = this.records[iter1802]; + output.writeI64(iter1802); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_averageKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1807 in this.records) { + if (this.records.hasOwnProperty(iter1807)) { + iter1807 = this.records[iter1807]; + output.writeI64(iter1807); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1812 in this.records) { + if (this.records.hasOwnProperty(iter1812)) { + iter1812 = this.records[iter1812]; + output.writeI64(iter1812); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1817 in this.records) { + if (this.records.hasOwnProperty(iter1817)) { + iter1817 = this.records[iter1817]; + output.writeI64(iter1817); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_countKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_countKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1822 in this.records) { + if (this.records.hasOwnProperty(iter1822)) { + iter1822 = this.records[iter1822]; + output.writeI64(iter1822); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1827 in this.records) { + if (this.records.hasOwnProperty(iter1827)) { + iter1827 = this.records[iter1827]; + output.writeI64(iter1827); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1832 in this.records) { + if (this.records.hasOwnProperty(iter1832)) { + iter1832 = this.records[iter1832]; + output.writeI64(iter1832); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_maxKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_maxKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1837 in this.records) { + if (this.records.hasOwnProperty(iter1837)) { + iter1837 = this.records[iter1837]; + output.writeI64(iter1837); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1842 in this.records) { + if (this.records.hasOwnProperty(iter1842)) { + iter1842 = this.records[iter1842]; + output.writeI64(iter1842); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1847 in this.records) { + if (this.records.hasOwnProperty(iter1847)) { + iter1847 = this.records[iter1847]; + output.writeI64(iter1847); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_minKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31849 = input.readMapBegin(); + const _size1848 = _rtmp31849.size || 0; + for (let _i1850 = 0; _i1850 < _size1848; ++_i1850) { + let key1851 = null; + let val1852 = null; + key1851 = input.readI64(); + val1852 = []; + const _rtmp31854 = input.readSetBegin(); + const _size1853 = _rtmp31854.size || 0; + for (let _i1855 = 0; _i1855 < _size1853; ++_i1855) { + let elem1856 = null; + elem1856 = new data_ttypes.TObject(); + elem1856.read(input); + val1852.push(elem1856); + } + input.readSetEnd(); + this.success[key1851] = val1852; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31861 = input.readMapBegin(); + const _size1860 = _rtmp31861.size || 0; + for (let _i1862 = 0; _i1862 < _size1860; ++_i1862) { + let key1863 = null; + let val1864 = null; + key1863 = input.readI64(); + val1864 = []; + const _rtmp31866 = input.readSetBegin(); + const _size1865 = _rtmp31866.size || 0; + for (let _i1867 = 0; _i1867 < _size1865; ++_i1867) { + let elem1868 = null; + elem1868 = new data_ttypes.TObject(); + elem1868.read(input); + val1864.push(elem1868); + } + input.readSetEnd(); + this.success[key1863] = val1864; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31873 = input.readMapBegin(); + const _size1872 = _rtmp31873.size || 0; + for (let _i1874 = 0; _i1874 < _size1872; ++_i1874) { + let key1875 = null; + let val1876 = null; + key1875 = input.readI64(); + val1876 = []; + const _rtmp31878 = input.readSetBegin(); + const _size1877 = _rtmp31878.size || 0; + for (let _i1879 = 0; _i1879 < _size1877; ++_i1879) { + let elem1880 = null; + elem1880 = new data_ttypes.TObject(); + elem1880.read(input); + val1876.push(elem1880); + } + input.readSetEnd(); + this.success[key1875] = val1876; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1888 in this.keys) { + if (this.keys.hasOwnProperty(iter1888)) { + iter1888 = this.keys[iter1888]; + output.writeString(iter1888); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31890 = input.readMapBegin(); + const _size1889 = _rtmp31890.size || 0; + for (let _i1891 = 0; _i1891 < _size1889; ++_i1891) { + let key1892 = null; + let val1893 = null; + key1892 = input.readI64(); + val1893 = {}; + const _rtmp31895 = input.readMapBegin(); + const _size1894 = _rtmp31895.size || 0; + for (let _i1896 = 0; _i1896 < _size1894; ++_i1896) { + let key1897 = null; + let val1898 = null; + key1897 = input.readString(); + val1898 = []; + const _rtmp31900 = input.readSetBegin(); + const _size1899 = _rtmp31900.size || 0; + for (let _i1901 = 0; _i1901 < _size1899; ++_i1901) { + let elem1902 = null; + elem1902 = new data_ttypes.TObject(); + elem1902.read(input); + val1898.push(elem1902); + } + input.readSetEnd(); + val1893[key1897] = val1898; + } + input.readMapEnd(); + this.success[key1892] = val1893; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1912 in this.keys) { + if (this.keys.hasOwnProperty(iter1912)) { + iter1912 = this.keys[iter1912]; + output.writeString(iter1912); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31914 = input.readMapBegin(); + const _size1913 = _rtmp31914.size || 0; + for (let _i1915 = 0; _i1915 < _size1913; ++_i1915) { + let key1916 = null; + let val1917 = null; + key1916 = input.readI64(); + val1917 = {}; + const _rtmp31919 = input.readMapBegin(); + const _size1918 = _rtmp31919.size || 0; + for (let _i1920 = 0; _i1920 < _size1918; ++_i1920) { + let key1921 = null; + let val1922 = null; + key1921 = input.readString(); + val1922 = []; + const _rtmp31924 = input.readSetBegin(); + const _size1923 = _rtmp31924.size || 0; + for (let _i1925 = 0; _i1925 < _size1923; ++_i1925) { + let elem1926 = null; + elem1926 = new data_ttypes.TObject(); + elem1926.read(input); + val1922.push(elem1926); + } + input.readSetEnd(); + val1917[key1921] = val1922; + } + input.readMapEnd(); + this.success[key1916] = val1917; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1936 in this.keys) { + if (this.keys.hasOwnProperty(iter1936)) { + iter1936 = this.keys[iter1936]; + output.writeString(iter1936); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31938 = input.readMapBegin(); + const _size1937 = _rtmp31938.size || 0; + for (let _i1939 = 0; _i1939 < _size1937; ++_i1939) { + let key1940 = null; + let val1941 = null; + key1940 = input.readI64(); + val1941 = {}; + const _rtmp31943 = input.readMapBegin(); + const _size1942 = _rtmp31943.size || 0; + for (let _i1944 = 0; _i1944 < _size1942; ++_i1944) { + let key1945 = null; + let val1946 = null; + key1945 = input.readString(); + val1946 = []; + const _rtmp31948 = input.readSetBegin(); + const _size1947 = _rtmp31948.size || 0; + for (let _i1949 = 0; _i1949 < _size1947; ++_i1949) { + let elem1950 = null; + elem1950 = new data_ttypes.TObject(); + elem1950.read(input); + val1946.push(elem1950); + } + input.readSetEnd(); + val1941[key1945] = val1946; + } + input.readMapEnd(); + this.success[key1940] = val1941; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1964 in this.keys) { + if (this.keys.hasOwnProperty(iter1964)) { + iter1964 = this.keys[iter1964]; + output.writeString(iter1964); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1965 in this.records) { + if (this.records.hasOwnProperty(iter1965)) { + iter1965 = this.records[iter1965]; + output.writeI64(iter1965); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31967 = input.readMapBegin(); + const _size1966 = _rtmp31967.size || 0; + for (let _i1968 = 0; _i1968 < _size1966; ++_i1968) { + let key1969 = null; + let val1970 = null; + key1969 = input.readI64(); + val1970 = {}; + const _rtmp31972 = input.readMapBegin(); + const _size1971 = _rtmp31972.size || 0; + for (let _i1973 = 0; _i1973 < _size1971; ++_i1973) { + let key1974 = null; + let val1975 = null; + key1974 = input.readString(); + val1975 = []; + const _rtmp31977 = input.readSetBegin(); + const _size1976 = _rtmp31977.size || 0; + for (let _i1978 = 0; _i1978 < _size1976; ++_i1978) { + let elem1979 = null; + elem1979 = new data_ttypes.TObject(); + elem1979.read(input); + val1975.push(elem1979); + } + input.readSetEnd(); + val1970[key1974] = val1975; + } + input.readMapEnd(); + this.success[key1969] = val1970; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1989 in this.records) { + if (this.records.hasOwnProperty(iter1989)) { + iter1989 = this.records[iter1989]; + output.writeI64(iter1989); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31991 = input.readMapBegin(); + const _size1990 = _rtmp31991.size || 0; + for (let _i1992 = 0; _i1992 < _size1990; ++_i1992) { + let key1993 = null; + let val1994 = null; + key1993 = input.readI64(); + val1994 = []; + const _rtmp31996 = input.readSetBegin(); + const _size1995 = _rtmp31996.size || 0; + for (let _i1997 = 0; _i1997 < _size1995; ++_i1997) { + let elem1998 = null; + elem1998 = new data_ttypes.TObject(); + elem1998.read(input); + val1994.push(elem1998); + } + input.readSetEnd(); + this.success[key1993] = val1994; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2006 in this.records) { + if (this.records.hasOwnProperty(iter2006)) { + iter2006 = this.records[iter2006]; + output.writeI64(iter2006); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32008 = input.readMapBegin(); + const _size2007 = _rtmp32008.size || 0; + for (let _i2009 = 0; _i2009 < _size2007; ++_i2009) { + let key2010 = null; + let val2011 = null; + key2010 = input.readI64(); + val2011 = []; + const _rtmp32013 = input.readSetBegin(); + const _size2012 = _rtmp32013.size || 0; + for (let _i2014 = 0; _i2014 < _size2012; ++_i2014) { + let elem2015 = null; + elem2015 = new data_ttypes.TObject(); + elem2015.read(input); + val2011.push(elem2015); + } + input.readSetEnd(); + this.success[key2010] = val2011; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2023 in this.records) { + if (this.records.hasOwnProperty(iter2023)) { + iter2023 = this.records[iter2023]; + output.writeI64(iter2023); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32025 = input.readMapBegin(); + const _size2024 = _rtmp32025.size || 0; + for (let _i2026 = 0; _i2026 < _size2024; ++_i2026) { + let key2027 = null; + let val2028 = null; + key2027 = input.readI64(); + val2028 = []; + const _rtmp32030 = input.readSetBegin(); + const _size2029 = _rtmp32030.size || 0; + for (let _i2031 = 0; _i2031 < _size2029; ++_i2031) { + let elem2032 = null; + elem2032 = new data_ttypes.TObject(); + elem2032.read(input); + val2028.push(elem2032); + } + input.readSetEnd(); + this.success[key2027] = val2028; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2044 in this.keys) { + if (this.keys.hasOwnProperty(iter2044)) { + iter2044 = this.keys[iter2044]; + output.writeString(iter2044); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2045 in this.records) { + if (this.records.hasOwnProperty(iter2045)) { + iter2045 = this.records[iter2045]; + output.writeI64(iter2045); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32047 = input.readMapBegin(); + const _size2046 = _rtmp32047.size || 0; + for (let _i2048 = 0; _i2048 < _size2046; ++_i2048) { + let key2049 = null; + let val2050 = null; + key2049 = input.readI64(); + val2050 = {}; + const _rtmp32052 = input.readMapBegin(); + const _size2051 = _rtmp32052.size || 0; + for (let _i2053 = 0; _i2053 < _size2051; ++_i2053) { + let key2054 = null; + let val2055 = null; + key2054 = input.readString(); + val2055 = []; + const _rtmp32057 = input.readSetBegin(); + const _size2056 = _rtmp32057.size || 0; + for (let _i2058 = 0; _i2058 < _size2056; ++_i2058) { + let elem2059 = null; + elem2059 = new data_ttypes.TObject(); + elem2059.read(input); + val2055.push(elem2059); + } + input.readSetEnd(); + val2050[key2054] = val2055; + } + input.readMapEnd(); + this.success[key2049] = val2050; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2073 in this.keys) { + if (this.keys.hasOwnProperty(iter2073)) { + iter2073 = this.keys[iter2073]; + output.writeString(iter2073); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2074 in this.records) { + if (this.records.hasOwnProperty(iter2074)) { + iter2074 = this.records[iter2074]; + output.writeI64(iter2074); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32076 = input.readMapBegin(); + const _size2075 = _rtmp32076.size || 0; + for (let _i2077 = 0; _i2077 < _size2075; ++_i2077) { + let key2078 = null; + let val2079 = null; + key2078 = input.readI64(); + val2079 = {}; + const _rtmp32081 = input.readMapBegin(); + const _size2080 = _rtmp32081.size || 0; + for (let _i2082 = 0; _i2082 < _size2080; ++_i2082) { + let key2083 = null; + let val2084 = null; + key2083 = input.readString(); + val2084 = []; + const _rtmp32086 = input.readSetBegin(); + const _size2085 = _rtmp32086.size || 0; + for (let _i2087 = 0; _i2087 < _size2085; ++_i2087) { + let elem2088 = null; + elem2088 = new data_ttypes.TObject(); + elem2088.read(input); + val2084.push(elem2088); + } + input.readSetEnd(); + val2079[key2083] = val2084; + } + input.readMapEnd(); + this.success[key2078] = val2079; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32095 = input.readMapBegin(); + const _size2094 = _rtmp32095.size || 0; + for (let _i2096 = 0; _i2096 < _size2094; ++_i2096) { + let key2097 = null; + let val2098 = null; + key2097 = input.readI64(); + val2098 = []; + const _rtmp32100 = input.readSetBegin(); + const _size2099 = _rtmp32100.size || 0; + for (let _i2101 = 0; _i2101 < _size2099; ++_i2101) { + let elem2102 = null; + elem2102 = new data_ttypes.TObject(); + elem2102.read(input); + val2098.push(elem2102); + } + input.readSetEnd(); + this.success[key2097] = val2098; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32107 = input.readMapBegin(); + const _size2106 = _rtmp32107.size || 0; + for (let _i2108 = 0; _i2108 < _size2106; ++_i2108) { + let key2109 = null; + let val2110 = null; + key2109 = input.readI64(); + val2110 = []; + const _rtmp32112 = input.readSetBegin(); + const _size2111 = _rtmp32112.size || 0; + for (let _i2113 = 0; _i2113 < _size2111; ++_i2113) { + let elem2114 = null; + elem2114 = new data_ttypes.TObject(); + elem2114.read(input); + val2110.push(elem2114); + } + input.readSetEnd(); + this.success[key2109] = val2110; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32119 = input.readMapBegin(); + const _size2118 = _rtmp32119.size || 0; + for (let _i2120 = 0; _i2120 < _size2118; ++_i2120) { + let key2121 = null; + let val2122 = null; + key2121 = input.readI64(); + val2122 = []; + const _rtmp32124 = input.readSetBegin(); + const _size2123 = _rtmp32124.size || 0; + for (let _i2125 = 0; _i2125 < _size2123; ++_i2125) { + let elem2126 = null; + elem2126 = new data_ttypes.TObject(); + elem2126.read(input); + val2122.push(elem2126); + } + input.readSetEnd(); + this.success[key2121] = val2122; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCcl_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCcl_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2134 in this.keys) { + if (this.keys.hasOwnProperty(iter2134)) { + iter2134 = this.keys[iter2134]; + output.writeString(iter2134); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32136 = input.readMapBegin(); + const _size2135 = _rtmp32136.size || 0; + for (let _i2137 = 0; _i2137 < _size2135; ++_i2137) { + let key2138 = null; + let val2139 = null; + key2138 = input.readI64(); + val2139 = {}; + const _rtmp32141 = input.readMapBegin(); + const _size2140 = _rtmp32141.size || 0; + for (let _i2142 = 0; _i2142 < _size2140; ++_i2142) { + let key2143 = null; + let val2144 = null; + key2143 = input.readString(); + val2144 = []; + const _rtmp32146 = input.readSetBegin(); + const _size2145 = _rtmp32146.size || 0; + for (let _i2147 = 0; _i2147 < _size2145; ++_i2147) { + let elem2148 = null; + elem2148 = new data_ttypes.TObject(); + elem2148.read(input); + val2144.push(elem2148); + } + input.readSetEnd(); + val2139[key2143] = val2144; + } + input.readMapEnd(); + this.success[key2138] = val2139; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCclTime_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCclTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2158 in this.keys) { + if (this.keys.hasOwnProperty(iter2158)) { + iter2158 = this.keys[iter2158]; + output.writeString(iter2158); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32160 = input.readMapBegin(); + const _size2159 = _rtmp32160.size || 0; + for (let _i2161 = 0; _i2161 < _size2159; ++_i2161) { + let key2162 = null; + let val2163 = null; + key2162 = input.readI64(); + val2163 = {}; + const _rtmp32165 = input.readMapBegin(); + const _size2164 = _rtmp32165.size || 0; + for (let _i2166 = 0; _i2166 < _size2164; ++_i2166) { + let key2167 = null; + let val2168 = null; + key2167 = input.readString(); + val2168 = []; + const _rtmp32170 = input.readSetBegin(); + const _size2169 = _rtmp32170.size || 0; + for (let _i2171 = 0; _i2171 < _size2169; ++_i2171) { + let elem2172 = null; + elem2172 = new data_ttypes.TObject(); + elem2172.read(input); + val2168.push(elem2172); + } + input.readSetEnd(); + val2163[key2167] = val2168; + } + input.readMapEnd(); + this.success[key2162] = val2163; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCclTimestr_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCclTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2182 in this.keys) { + if (this.keys.hasOwnProperty(iter2182)) { + iter2182 = this.keys[iter2182]; + output.writeString(iter2182); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32184 = input.readMapBegin(); + const _size2183 = _rtmp32184.size || 0; + for (let _i2185 = 0; _i2185 < _size2183; ++_i2185) { + let key2186 = null; + let val2187 = null; + key2186 = input.readI64(); + val2187 = {}; + const _rtmp32189 = input.readMapBegin(); + const _size2188 = _rtmp32189.size || 0; + for (let _i2190 = 0; _i2190 < _size2188; ++_i2190) { + let key2191 = null; + let val2192 = null; + key2191 = input.readString(); + val2192 = []; + const _rtmp32194 = input.readSetBegin(); + const _size2193 = _rtmp32194.size || 0; + for (let _i2195 = 0; _i2195 < _size2193; ++_i2195) { + let elem2196 = null; + elem2196 = new data_ttypes.TObject(); + elem2196.read(input); + val2192.push(elem2196); + } + input.readSetEnd(); + val2187[key2191] = val2192; + } + input.readMapEnd(); + this.success[key2186] = val2187; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32203 = input.readMapBegin(); + const _size2202 = _rtmp32203.size || 0; + for (let _i2204 = 0; _i2204 < _size2202; ++_i2204) { + let key2205 = null; + let val2206 = null; + key2205 = input.readI64(); + val2206 = []; + const _rtmp32208 = input.readSetBegin(); + const _size2207 = _rtmp32208.size || 0; + for (let _i2209 = 0; _i2209 < _size2207; ++_i2209) { + let elem2210 = null; + elem2210 = new data_ttypes.TObject(); + elem2210.read(input); + val2206.push(elem2210); + } + input.readSetEnd(); + this.success[key2205] = val2206; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32215 = input.readMapBegin(); + const _size2214 = _rtmp32215.size || 0; + for (let _i2216 = 0; _i2216 < _size2214; ++_i2216) { + let key2217 = null; + let val2218 = null; + key2217 = input.readI64(); + val2218 = []; + const _rtmp32220 = input.readSetBegin(); + const _size2219 = _rtmp32220.size || 0; + for (let _i2221 = 0; _i2221 < _size2219; ++_i2221) { + let elem2222 = null; + elem2222 = new data_ttypes.TObject(); + elem2222.read(input); + val2218.push(elem2222); + } + input.readSetEnd(); + this.success[key2217] = val2218; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32227 = input.readMapBegin(); + const _size2226 = _rtmp32227.size || 0; + for (let _i2228 = 0; _i2228 < _size2226; ++_i2228) { + let key2229 = null; + let val2230 = null; + key2229 = input.readI64(); + val2230 = []; + const _rtmp32232 = input.readSetBegin(); + const _size2231 = _rtmp32232.size || 0; + for (let _i2233 = 0; _i2233 < _size2231; ++_i2233) { + let elem2234 = null; + elem2234 = new data_ttypes.TObject(); + elem2234.read(input); + val2230.push(elem2234); + } + input.readSetEnd(); + this.success[key2229] = val2230; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCriteria_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteria_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2242 in this.keys) { + if (this.keys.hasOwnProperty(iter2242)) { + iter2242 = this.keys[iter2242]; + output.writeString(iter2242); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32244 = input.readMapBegin(); + const _size2243 = _rtmp32244.size || 0; + for (let _i2245 = 0; _i2245 < _size2243; ++_i2245) { + let key2246 = null; + let val2247 = null; + key2246 = input.readI64(); + val2247 = {}; + const _rtmp32249 = input.readMapBegin(); + const _size2248 = _rtmp32249.size || 0; + for (let _i2250 = 0; _i2250 < _size2248; ++_i2250) { + let key2251 = null; + let val2252 = null; + key2251 = input.readString(); + val2252 = []; + const _rtmp32254 = input.readSetBegin(); + const _size2253 = _rtmp32254.size || 0; + for (let _i2255 = 0; _i2255 < _size2253; ++_i2255) { + let elem2256 = null; + elem2256 = new data_ttypes.TObject(); + elem2256.read(input); + val2252.push(elem2256); + } + input.readSetEnd(); + val2247[key2251] = val2252; + } + input.readMapEnd(); + this.success[key2246] = val2247; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCriteriaTime_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteriaTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2266 in this.keys) { + if (this.keys.hasOwnProperty(iter2266)) { + iter2266 = this.keys[iter2266]; + output.writeString(iter2266); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32268 = input.readMapBegin(); + const _size2267 = _rtmp32268.size || 0; + for (let _i2269 = 0; _i2269 < _size2267; ++_i2269) { + let key2270 = null; + let val2271 = null; + key2270 = input.readI64(); + val2271 = {}; + const _rtmp32273 = input.readMapBegin(); + const _size2272 = _rtmp32273.size || 0; + for (let _i2274 = 0; _i2274 < _size2272; ++_i2274) { + let key2275 = null; + let val2276 = null; + key2275 = input.readString(); + val2276 = []; + const _rtmp32278 = input.readSetBegin(); + const _size2277 = _rtmp32278.size || 0; + for (let _i2279 = 0; _i2279 < _size2277; ++_i2279) { + let elem2280 = null; + elem2280 = new data_ttypes.TObject(); + elem2280.read(input); + val2276.push(elem2280); + } + input.readSetEnd(); + val2271[key2275] = val2276; + } + input.readMapEnd(); + this.success[key2270] = val2271; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCriteriaTimestr_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteriaTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2290 in this.keys) { + if (this.keys.hasOwnProperty(iter2290)) { + iter2290 = this.keys[iter2290]; + output.writeString(iter2290); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_navigateKeysCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32292 = input.readMapBegin(); + const _size2291 = _rtmp32292.size || 0; + for (let _i2293 = 0; _i2293 < _size2291; ++_i2293) { + let key2294 = null; + let val2295 = null; + key2294 = input.readI64(); + val2295 = {}; + const _rtmp32297 = input.readMapBegin(); + const _size2296 = _rtmp32297.size || 0; + for (let _i2298 = 0; _i2298 < _size2296; ++_i2298) { + let key2299 = null; + let val2300 = null; + key2299 = input.readString(); + val2300 = []; + const _rtmp32302 = input.readSetBegin(); + const _size2301 = _rtmp32302.size || 0; + for (let _i2303 = 0; _i2303 < _size2301; ++_i2303) { + let elem2304 = null; + elem2304 = new data_ttypes.TObject(); + elem2304.read(input); + val2300.push(elem2304); + } + input.readSetEnd(); + val2295[key2299] = val2300; + } + input.readMapEnd(); + this.success[key2294] = val2295; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getServerEnvironment_args = class { + constructor(args) { + this.creds = null; + this.token = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.TransactionToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_getServerEnvironment_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 2); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getServerEnvironment_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_getServerVersion_args = class { + constructor(args) { + } + + write (output) { + output.writeStructBegin('ConcourseService_getServerVersion_args'); + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_getServerVersion_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_time_args = class { + constructor(args) { + this.creds = null; + this.token = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.TransactionToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_time_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 2); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_time_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_timePhrase_args = class { + constructor(args) { + this.phrase = null; + this.creds = null; + this.token = null; + this.environment = null; + if (args) { + if (args.phrase !== undefined && args.phrase !== null) { + this.phrase = args.phrase; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.TransactionToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_timePhrase_args'); + if (this.phrase !== null && this.phrase !== undefined) { + output.writeFieldBegin('phrase', Thrift.Type.STRING, 1); + output.writeString(this.phrase); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 3); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_timePhrase_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseService_invokeManagement_args = class { + constructor(args) { + this.method = null; + this.params = null; + this.creds = null; + if (args) { + if (args.method !== undefined && args.method !== null) { + this.method = args.method; + } + if (args.params !== undefined && args.params !== null) { + this.params = Thrift.copyList(args.params, [complex_ttypes.ComplexTObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + } + } + + write (output) { + output.writeStructBegin('ConcourseService_invokeManagement_args'); + if (this.method !== null && this.method !== undefined) { + output.writeFieldBegin('method', Thrift.Type.STRING, 2); + output.writeString(this.method); + output.writeFieldEnd(); + } + if (this.params !== null && this.params !== undefined) { + output.writeFieldBegin('params', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.params.length); + for (let iter2314 in this.params) { + if (this.params.hasOwnProperty(iter2314)) { + iter2314 = this.params[iter2314]; + iter2314.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } +}; +const ConcourseService_invokeManagement_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.ManagementException) { + this.ex2 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new complex_ttypes.ComplexTObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new complex_ttypes.ComplexTObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.ManagementException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } +}; +const ConcourseServiceClient = exports.Client = class { + constructor(output, pClass) { + this.output = output; + this.pClass = pClass; + this._seqid = 0; + this._reqs = {}; + } + seqid () { return this._seqid; } + new_seqid () { return this._seqid += 1; } + + abort (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_abort(creds, transaction, environment); + }); + } + + send_abort (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_abort_args(params); + try { + output.writeMessageBegin('abort', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_abort (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_abort_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + callback(null); + } + + addKeyValue (key, value, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_addKeyValue(key, value, creds, transaction, environment); + }); + } + + send_addKeyValue (key, value, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_addKeyValue_args(params); + try { + output.writeMessageBegin('addKeyValue', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_addKeyValue (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_addKeyValue_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('addKeyValue failed: unknown result'); + } + + addKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_addKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_addKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_addKeyValueRecord_args(params); + try { + output.writeMessageBegin('addKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_addKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_addKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('addKeyValueRecord failed: unknown result'); + } + + addKeyValueRecords (key, value, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_addKeyValueRecords(key, value, records, creds, transaction, environment); + }); + } + + send_addKeyValueRecords (key, value, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_addKeyValueRecords_args(params); + try { + output.writeMessageBegin('addKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_addKeyValueRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_addKeyValueRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('addKeyValueRecords failed: unknown result'); + } + + auditRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecord(record, creds, transaction, environment); + }); + } + + send_auditRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecord_args(params); + try { + output.writeMessageBegin('auditRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecord failed: unknown result'); + } + + auditRecordStart (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStart(record, start, creds, transaction, environment); + }); + } + + send_auditRecordStart (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStart_args(params); + try { + output.writeMessageBegin('auditRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStart failed: unknown result'); + } + + auditRecordStartstr (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStartstr(record, start, creds, transaction, environment); + }); + } + + send_auditRecordStartstr (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStartstr_args(params); + try { + output.writeMessageBegin('auditRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStartstr failed: unknown result'); + } + + auditRecordStartEnd (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStartEnd(record, start, tend, creds, transaction, environment); + }); + } + + send_auditRecordStartEnd (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStartEnd_args(params); + try { + output.writeMessageBegin('auditRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStartEnd failed: unknown result'); + } + + auditRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStartstrEndstr(record, start, tend, creds, transaction, environment); + }); + } + + send_auditRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('auditRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStartstrEndstr failed: unknown result'); + } + + auditKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_auditKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecord_args(params); + try { + output.writeMessageBegin('auditKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecord failed: unknown result'); + } + + auditKeyRecordStart (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStart(key, record, start, creds, transaction, environment); + }); + } + + send_auditKeyRecordStart (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStart_args(params); + try { + output.writeMessageBegin('auditKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStart failed: unknown result'); + } + + auditKeyRecordStartstr (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStartstr(key, record, start, creds, transaction, environment); + }); + } + + send_auditKeyRecordStartstr (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStartstr_args(params); + try { + output.writeMessageBegin('auditKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStartstr failed: unknown result'); + } + + auditKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); + }); + } + + send_auditKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStartEnd_args(params); + try { + output.writeMessageBegin('auditKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStartEnd failed: unknown result'); + } + + auditKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); + }); + } + + send_auditKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('auditKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStartstrEndstr failed: unknown result'); + } + + browseKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKey(key, creds, transaction, environment); + }); + } + + send_browseKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKey_args(params); + try { + output.writeMessageBegin('browseKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKey failed: unknown result'); + } + + browseKeys (keys, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeys(keys, creds, transaction, environment); + }); + } + + send_browseKeys (keys, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeys_args(params); + try { + output.writeMessageBegin('browseKeys', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeys (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeys_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeys failed: unknown result'); + } + + browseKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_browseKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeyTime_args(params); + try { + output.writeMessageBegin('browseKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeyTime failed: unknown result'); + } + + browseKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_browseKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeyTimestr_args(params); + try { + output.writeMessageBegin('browseKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeyTimestr failed: unknown result'); + } + + browseKeysTime (keys, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeysTime(keys, timestamp, creds, transaction, environment); + }); + } + + send_browseKeysTime (keys, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeysTime_args(params); + try { + output.writeMessageBegin('browseKeysTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeysTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeysTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeysTime failed: unknown result'); + } + + browseKeysTimestr (keys, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeysTimestr(keys, timestamp, creds, transaction, environment); + }); + } + + send_browseKeysTimestr (keys, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeysTimestr_args(params); + try { + output.writeMessageBegin('browseKeysTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeysTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeysTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeysTimestr failed: unknown result'); + } + + chronologizeKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecord_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecord failed: unknown result'); + } + + chronologizeKeyRecordStart (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStart(key, record, start, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStart (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStart_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStart failed: unknown result'); + } + + chronologizeKeyRecordStartstr (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStartstr(key, record, start, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStartstr (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStartstr_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStartstr failed: unknown result'); + } + + chronologizeKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStartEnd_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStartEnd failed: unknown result'); + } + + chronologizeKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStartstrEndstr failed: unknown result'); + } + + clearRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearRecord(record, creds, transaction, environment); + }); + } + + send_clearRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearRecord_args(params); + try { + output.writeMessageBegin('clearRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearRecords(records, creds, transaction, environment); + }); + } + + send_clearRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearRecords_args(params); + try { + output.writeMessageBegin('clearRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_clearKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeyRecord_args(params); + try { + output.writeMessageBegin('clearKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_clearKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeysRecord_args(params); + try { + output.writeMessageBegin('clearKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_clearKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeyRecords_args(params); + try { + output.writeMessageBegin('clearKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_clearKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeysRecords_args(params); + try { + output.writeMessageBegin('clearKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + commit (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_commit(creds, transaction, environment); + }); + } + + send_commit (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_commit_args(params); + try { + output.writeMessageBegin('commit', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_commit (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_commit_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('commit failed: unknown result'); + } + + describe (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describe(creds, transaction, environment); + }); + } + + send_describe (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describe_args(params); + try { + output.writeMessageBegin('describe', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describe (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describe_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describe failed: unknown result'); + } + + describeTime (timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeTime(timestamp, creds, transaction, environment); + }); + } + + send_describeTime (timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeTime_args(params); + try { + output.writeMessageBegin('describeTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeTime failed: unknown result'); + } + + describeTimestr (timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeTimestr(timestamp, creds, transaction, environment); + }); + } + + send_describeTimestr (timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeTimestr_args(params); + try { + output.writeMessageBegin('describeTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeTimestr failed: unknown result'); + } + + describeRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecord(record, creds, transaction, environment); + }); + } + + send_describeRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecord_args(params); + try { + output.writeMessageBegin('describeRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecord failed: unknown result'); + } + + describeRecordTime (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordTime(record, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordTime (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordTime_args(params); + try { + output.writeMessageBegin('describeRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordTime failed: unknown result'); + } + + describeRecordTimestr (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordTimestr(record, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordTimestr (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordTimestr_args(params); + try { + output.writeMessageBegin('describeRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordTimestr failed: unknown result'); + } + + describeRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecords(records, creds, transaction, environment); + }); + } + + send_describeRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecords_args(params); + try { + output.writeMessageBegin('describeRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecords failed: unknown result'); + } + + describeRecordsTime (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordsTime(records, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordsTime (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordsTime_args(params); + try { + output.writeMessageBegin('describeRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordsTime failed: unknown result'); + } + + describeRecordsTimestr (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordsTimestr(records, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordsTimestr (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordsTimestr_args(params); + try { + output.writeMessageBegin('describeRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordsTimestr failed: unknown result'); + } + + diffRecordStart (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStart(record, start, creds, transaction, environment); + }); + } + + send_diffRecordStart (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStart_args(params); + try { + output.writeMessageBegin('diffRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStart failed: unknown result'); + } + + diffRecordStartstr (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStartstr(record, start, creds, transaction, environment); + }); + } + + send_diffRecordStartstr (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStartstr_args(params); + try { + output.writeMessageBegin('diffRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStartstr failed: unknown result'); + } + + diffRecordStartEnd (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStartEnd(record, start, tend, creds, transaction, environment); + }); + } + + send_diffRecordStartEnd (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStartEnd_args(params); + try { + output.writeMessageBegin('diffRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStartEnd failed: unknown result'); + } + + diffRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStartstrEndstr(record, start, tend, creds, transaction, environment); + }); + } + + send_diffRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('diffRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStartstrEndstr failed: unknown result'); + } + + diffKeyRecordStart (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStart(key, record, start, creds, transaction, environment); + }); + } + + send_diffKeyRecordStart (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStart_args(params); + try { + output.writeMessageBegin('diffKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStart failed: unknown result'); + } + + diffKeyRecordStartstr (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStartstr(key, record, start, creds, transaction, environment); + }); + } + + send_diffKeyRecordStartstr (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStartstr_args(params); + try { + output.writeMessageBegin('diffKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStartstr failed: unknown result'); + } + + diffKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStartEnd_args(params); + try { + output.writeMessageBegin('diffKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStartEnd failed: unknown result'); + } + + diffKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('diffKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStartstrEndstr failed: unknown result'); + } + + diffKeyStart (key, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStart(key, start, creds, transaction, environment); + }); + } + + send_diffKeyStart (key, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStart_args(params); + try { + output.writeMessageBegin('diffKeyStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStart failed: unknown result'); + } + + diffKeyStartstr (key, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStartstr(key, start, creds, transaction, environment); + }); + } + + send_diffKeyStartstr (key, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStartstr_args(params); + try { + output.writeMessageBegin('diffKeyStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStartstr failed: unknown result'); + } + + diffKeyStartEnd (key, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStartEnd(key, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyStartEnd (key, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStartEnd_args(params); + try { + output.writeMessageBegin('diffKeyStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStartEnd failed: unknown result'); + } + + diffKeyStartstrEndstr (key, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStartstrEndstr(key, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyStartstrEndstr (key, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStartstrEndstr_args(params); + try { + output.writeMessageBegin('diffKeyStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStartstrEndstr failed: unknown result'); + } + + invokePlugin (id, method, params, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_invokePlugin(id, method, params, creds, transaction, environment); + }); + } + + send_invokePlugin (id, method, params, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + id: id, + method: method, + params: params, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_invokePlugin_args(params); + try { + output.writeMessageBegin('invokePlugin', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_invokePlugin (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_invokePlugin_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('invokePlugin failed: unknown result'); + } + + login (username, password, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_login(username, password, environment); + }); + } + + send_login (username, password, environment) { + const output = new this.pClass(this.output); + const params = { + username: username, + password: password, + environment: environment + }; + const args = new ConcourseService_login_args(params); + try { + output.writeMessageBegin('login', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_login (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_login_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('login failed: unknown result'); + } + + logout (token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_logout(token, environment); + }); + } + + send_logout (token, environment) { + const output = new this.pClass(this.output); + const params = { + token: token, + environment: environment + }; + const args = new ConcourseService_logout_args(params); + try { + output.writeMessageBegin('logout', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_logout (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_logout_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + callback(null); + } + + stage (token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_stage(token, environment); + }); + } + + send_stage (token, environment) { + const output = new this.pClass(this.output); + const params = { + token: token, + environment: environment + }; + const args = new ConcourseService_stage_args(params); + try { + output.writeMessageBegin('stage', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_stage (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_stage_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('stage failed: unknown result'); + } + + insertJson (json, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_insertJson(json, creds, transaction, environment); + }); + } + + send_insertJson (json, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + json: json, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_insertJson_args(params); + try { + output.writeMessageBegin('insertJson', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_insertJson (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_insertJson_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('insertJson failed: unknown result'); + } + + insertJsonRecord (json, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_insertJsonRecord(json, record, creds, transaction, environment); + }); + } + + send_insertJsonRecord (json, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + json: json, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_insertJsonRecord_args(params); + try { + output.writeMessageBegin('insertJsonRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_insertJsonRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_insertJsonRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('insertJsonRecord failed: unknown result'); + } + + insertJsonRecords (json, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_insertJsonRecords(json, records, creds, transaction, environment); + }); + } + + send_insertJsonRecords (json, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + json: json, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_insertJsonRecords_args(params); + try { + output.writeMessageBegin('insertJsonRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_insertJsonRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_insertJsonRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('insertJsonRecords failed: unknown result'); + } + + removeKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_removeKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_removeKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_removeKeyValueRecord_args(params); + try { + output.writeMessageBegin('removeKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_removeKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_removeKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('removeKeyValueRecord failed: unknown result'); + } + + removeKeyValueRecords (key, value, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_removeKeyValueRecords(key, value, records, creds, transaction, environment); + }); + } + + send_removeKeyValueRecords (key, value, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_removeKeyValueRecords_args(params); + try { + output.writeMessageBegin('removeKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_removeKeyValueRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_removeKeyValueRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('removeKeyValueRecords failed: unknown result'); + } + + setKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_setKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_setKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_setKeyValueRecord_args(params); + try { + output.writeMessageBegin('setKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_setKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_setKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + setKeyValue (key, value, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_setKeyValue(key, value, creds, transaction, environment); + }); + } + + send_setKeyValue (key, value, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_setKeyValue_args(params); + try { + output.writeMessageBegin('setKeyValue', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_setKeyValue (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_setKeyValue_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('setKeyValue failed: unknown result'); + } + + setKeyValueRecords (key, value, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_setKeyValueRecords(key, value, records, creds, transaction, environment); + }); + } + + send_setKeyValueRecords (key, value, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_setKeyValueRecords_args(params); + try { + output.writeMessageBegin('setKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_setKeyValueRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_setKeyValueRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + reconcileKeyRecordValues (key, record, values, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_reconcileKeyRecordValues(key, record, values, creds, transaction, environment); + }); + } + + send_reconcileKeyRecordValues (key, record, values, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + values: values, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_reconcileKeyRecordValues_args(params); + try { + output.writeMessageBegin('reconcileKeyRecordValues', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_reconcileKeyRecordValues (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_reconcileKeyRecordValues_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + inventory (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_inventory(creds, transaction, environment); + }); + } + + send_inventory (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_inventory_args(params); + try { + output.writeMessageBegin('inventory', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_inventory (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_inventory_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('inventory failed: unknown result'); + } + + selectRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecord(record, creds, transaction, environment); + }); + } + + send_selectRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecord_args(params); + try { + output.writeMessageBegin('selectRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecord failed: unknown result'); + } + + selectRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecords(records, creds, transaction, environment); + }); + } + + send_selectRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecords_args(params); + try { + output.writeMessageBegin('selectRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecords failed: unknown result'); + } + + selectRecordTime (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordTime(record, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordTime (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordTime_args(params); + try { + output.writeMessageBegin('selectRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordTime failed: unknown result'); + } + + selectRecordTimestr (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordTimestr(record, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordTimestr (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordTimestr_args(params); + try { + output.writeMessageBegin('selectRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordTimestr failed: unknown result'); + } + + selectRecordsTime (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordsTime(records, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordsTime (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordsTime_args(params); + try { + output.writeMessageBegin('selectRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordsTime failed: unknown result'); + } + + selectRecordsTimestr (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordsTimestr(records, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordsTimestr (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordsTimestr_args(params); + try { + output.writeMessageBegin('selectRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordsTimestr failed: unknown result'); + } + + selectKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_selectKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecord_args(params); + try { + output.writeMessageBegin('selectKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecord failed: unknown result'); + } + + selectKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordTime_args(params); + try { + output.writeMessageBegin('selectKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordTime failed: unknown result'); + } + + selectKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('selectKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordTimestr failed: unknown result'); + } + + selectKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_selectKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecord_args(params); + try { + output.writeMessageBegin('selectKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecord failed: unknown result'); + } + + selectKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordTime_args(params); + try { + output.writeMessageBegin('selectKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordTime failed: unknown result'); + } + + selectKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('selectKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordTimestr failed: unknown result'); + } + + selectKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_selectKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecords_args(params); + try { + output.writeMessageBegin('selectKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecords failed: unknown result'); + } + + selectKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_selectKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecords_args(params); + try { + output.writeMessageBegin('selectKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecords failed: unknown result'); + } + + selectKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordsTime_args(params); + try { + output.writeMessageBegin('selectKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordsTime failed: unknown result'); + } + + selectKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('selectKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordsTimestr failed: unknown result'); + } + + selectKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordsTime_args(params); + try { + output.writeMessageBegin('selectKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordsTime failed: unknown result'); + } + + selectKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('selectKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordsTimestr failed: unknown result'); + } + + selectCriteria (criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCriteria(criteria, creds, transaction, environment); + }); + } + + send_selectCriteria (criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCriteria_args(params); + try { + output.writeMessageBegin('selectCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCriteria failed: unknown result'); + } + + selectCcl (ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCcl(ccl, creds, transaction, environment); + }); + } + + send_selectCcl (ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCcl_args(params); + try { + output.writeMessageBegin('selectCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCcl failed: unknown result'); + } + + selectCriteriaTime (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCriteriaTime(criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectCriteriaTime (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCriteriaTime_args(params); + try { + output.writeMessageBegin('selectCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCriteriaTime failed: unknown result'); + } + + selectCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCriteriaTimestr(criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCriteriaTimestr_args(params); + try { + output.writeMessageBegin('selectCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCriteriaTimestr failed: unknown result'); + } + + selectCclTime (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCclTime(ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectCclTime (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCclTime_args(params); + try { + output.writeMessageBegin('selectCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCclTime failed: unknown result'); + } + + selectCclTimestr (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCclTimestr(ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectCclTimestr (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCclTimestr_args(params); + try { + output.writeMessageBegin('selectCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCclTimestr failed: unknown result'); + } + + selectKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_selectKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCriteria_args(params); + try { + output.writeMessageBegin('selectKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCriteria failed: unknown result'); + } + + selectKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_selectKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCcl_args(params); + try { + output.writeMessageBegin('selectKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCcl failed: unknown result'); + } + + selectKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('selectKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCriteriaTime failed: unknown result'); + } + + selectKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('selectKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCriteriaTimestr failed: unknown result'); + } + + selectKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCclTime_args(params); + try { + output.writeMessageBegin('selectKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCclTime failed: unknown result'); + } + + selectKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCclTimestr_args(params); + try { + output.writeMessageBegin('selectKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCclTimestr failed: unknown result'); + } + + selectKeysCriteria (keys, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCriteria(keys, criteria, creds, transaction, environment); + }); + } + + send_selectKeysCriteria (keys, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCriteria_args(params); + try { + output.writeMessageBegin('selectKeysCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCriteria failed: unknown result'); + } + + selectKeysCcl (keys, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCcl(keys, ccl, creds, transaction, environment); + }); + } + + send_selectKeysCcl (keys, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCcl_args(params); + try { + output.writeMessageBegin('selectKeysCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCcl failed: unknown result'); + } + + selectKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCriteriaTime_args(params); + try { + output.writeMessageBegin('selectKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCriteriaTime failed: unknown result'); + } + + selectKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCriteriaTimestr_args(params); + try { + output.writeMessageBegin('selectKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCriteriaTimestr failed: unknown result'); + } + + selectKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCclTime_args(params); + try { + output.writeMessageBegin('selectKeysCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCclTime failed: unknown result'); + } + + selectKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCclTimestr_args(params); + try { + output.writeMessageBegin('selectKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCclTimestr failed: unknown result'); + } + + getKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_getKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecord_args(params); + try { + output.writeMessageBegin('getKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecord failed: unknown result'); + } + + getKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordTime_args(params); + try { + output.writeMessageBegin('getKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordTime failed: unknown result'); + } + + getKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('getKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordTimestr failed: unknown result'); + } + + getKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_getKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecord_args(params); + try { + output.writeMessageBegin('getKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecord failed: unknown result'); + } + + getKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordTime_args(params); + try { + output.writeMessageBegin('getKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordTime failed: unknown result'); + } + + getKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('getKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordTimestr failed: unknown result'); + } + + getKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_getKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecords_args(params); + try { + output.writeMessageBegin('getKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecords failed: unknown result'); + } + + getKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_getKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecords_args(params); + try { + output.writeMessageBegin('getKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecords failed: unknown result'); + } + + getKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordsTime_args(params); + try { + output.writeMessageBegin('getKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordsTime failed: unknown result'); + } + + getKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('getKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordsTimestr failed: unknown result'); + } + + getKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordsTime_args(params); + try { + output.writeMessageBegin('getKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordsTime failed: unknown result'); + } + + getKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('getKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordsTimestr failed: unknown result'); + } + + getKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_getKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCriteria_args(params); + try { + output.writeMessageBegin('getKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCriteria failed: unknown result'); + } + + getCriteria (criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCriteria(criteria, creds, transaction, environment); + }); + } + + send_getCriteria (criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCriteria_args(params); + try { + output.writeMessageBegin('getCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCriteria failed: unknown result'); + } + + getCcl (ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCcl(ccl, creds, transaction, environment); + }); + } + + send_getCcl (ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCcl_args(params); + try { + output.writeMessageBegin('getCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCcl failed: unknown result'); + } + + getCriteriaTime (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCriteriaTime(criteria, timestamp, creds, transaction, environment); + }); + } + + send_getCriteriaTime (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCriteriaTime_args(params); + try { + output.writeMessageBegin('getCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCriteriaTime failed: unknown result'); + } + + getCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCriteriaTimestr(criteria, timestamp, creds, transaction, environment); + }); + } + + send_getCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCriteriaTimestr_args(params); + try { + output.writeMessageBegin('getCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCriteriaTimestr failed: unknown result'); + } + + getCclTime (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCclTime(ccl, timestamp, creds, transaction, environment); + }); + } + + send_getCclTime (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCclTime_args(params); + try { + output.writeMessageBegin('getCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCclTime failed: unknown result'); + } + + getCclTimestr (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCclTimestr(ccl, timestamp, creds, transaction, environment); + }); + } + + send_getCclTimestr (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCclTimestr_args(params); + try { + output.writeMessageBegin('getCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCclTimestr failed: unknown result'); + } + + getKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_getKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCcl_args(params); + try { + output.writeMessageBegin('getKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCcl failed: unknown result'); + } + + getKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('getKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCriteriaTime failed: unknown result'); + } + + getKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('getKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCriteriaTimestr failed: unknown result'); + } + + getKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCclTime_args(params); + try { + output.writeMessageBegin('getKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCclTime failed: unknown result'); + } + + getKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCclTimestr_args(params); + try { + output.writeMessageBegin('getKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCclTimestr failed: unknown result'); + } + + getKeysCriteria (keys, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCriteria(keys, criteria, creds, transaction, environment); + }); + } + + send_getKeysCriteria (keys, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCriteria_args(params); + try { + output.writeMessageBegin('getKeysCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCriteria failed: unknown result'); + } + + getKeysCcl (keys, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCcl(keys, ccl, creds, transaction, environment); + }); + } + + send_getKeysCcl (keys, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCcl_args(params); + try { + output.writeMessageBegin('getKeysCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCcl failed: unknown result'); + } + + getKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCriteriaTime_args(params); + try { + output.writeMessageBegin('getKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCriteriaTime failed: unknown result'); + } + + getKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCriteriaTimestr_args(params); + try { + output.writeMessageBegin('getKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCriteriaTimestr failed: unknown result'); + } + + getKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCclTime_args(params); + try { + output.writeMessageBegin('getKeysCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCclTime failed: unknown result'); + } + + getKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCclTimestr_args(params); + try { + output.writeMessageBegin('getKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCclTimestr failed: unknown result'); + } + + verifyKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_verifyKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyKeyValueRecord_args(params); + try { + output.writeMessageBegin('verifyKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyKeyValueRecord failed: unknown result'); + } + + verifyKeyValueRecordTime (key, value, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyKeyValueRecordTime(key, value, record, timestamp, creds, transaction, environment); + }); + } + + send_verifyKeyValueRecordTime (key, value, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyKeyValueRecordTime_args(params); + try { + output.writeMessageBegin('verifyKeyValueRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyKeyValueRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyKeyValueRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyKeyValueRecordTime failed: unknown result'); + } + + verifyKeyValueRecordTimestr (key, value, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyKeyValueRecordTimestr(key, value, record, timestamp, creds, transaction, environment); + }); + } + + send_verifyKeyValueRecordTimestr (key, value, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyKeyValueRecordTimestr_args(params); + try { + output.writeMessageBegin('verifyKeyValueRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyKeyValueRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyKeyValueRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyKeyValueRecordTimestr failed: unknown result'); + } + + jsonifyRecords (records, identifier, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_jsonifyRecords(records, identifier, creds, transaction, environment); + }); + } + + send_jsonifyRecords (records, identifier, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + identifier: identifier, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_jsonifyRecords_args(params); + try { + output.writeMessageBegin('jsonifyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_jsonifyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_jsonifyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('jsonifyRecords failed: unknown result'); + } + + jsonifyRecordsTime (records, timestamp, identifier, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_jsonifyRecordsTime(records, timestamp, identifier, creds, transaction, environment); + }); + } + + send_jsonifyRecordsTime (records, timestamp, identifier, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + identifier: identifier, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_jsonifyRecordsTime_args(params); + try { + output.writeMessageBegin('jsonifyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_jsonifyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_jsonifyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('jsonifyRecordsTime failed: unknown result'); + } + + jsonifyRecordsTimestr (records, timestamp, identifier, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_jsonifyRecordsTimestr(records, timestamp, identifier, creds, transaction, environment); + }); + } + + send_jsonifyRecordsTimestr (records, timestamp, identifier, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + identifier: identifier, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_jsonifyRecordsTimestr_args(params); + try { + output.writeMessageBegin('jsonifyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_jsonifyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_jsonifyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('jsonifyRecordsTimestr failed: unknown result'); + } + + findCriteria (criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findCriteria(criteria, creds, transaction, environment); + }); + } + + send_findCriteria (criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findCriteria_args(params); + try { + output.writeMessageBegin('findCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findCriteria failed: unknown result'); + } + + findCcl (ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findCcl(ccl, creds, transaction, environment); + }); + } + + send_findCcl (ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findCcl_args(params); + try { + output.writeMessageBegin('findCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findCcl failed: unknown result'); + } + + findKeyOperatorValues (key, operator, values, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorValues(key, operator, values, creds, transaction, environment); + }); + } + + send_findKeyOperatorValues (key, operator, values, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorValues_args(params); + try { + output.writeMessageBegin('findKeyOperatorValues', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorValues (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorValues_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorValues failed: unknown result'); + } + + findKeyOperatorValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorValuesTime(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorValuesTime_args(params); + try { + output.writeMessageBegin('findKeyOperatorValuesTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorValuesTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorValuesTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorValuesTime failed: unknown result'); + } + + findKeyOperatorValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorValuesTimestr(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorValuesTimestr_args(params); + try { + output.writeMessageBegin('findKeyOperatorValuesTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorValuesTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorValuesTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorValuesTimestr failed: unknown result'); + } + + findKeyOperatorstrValues (key, operator, values, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorstrValues(key, operator, values, creds, transaction, environment); + }); + } + + send_findKeyOperatorstrValues (key, operator, values, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorstrValues_args(params); + try { + output.writeMessageBegin('findKeyOperatorstrValues', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorstrValues (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorstrValues_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorstrValues failed: unknown result'); + } + + findKeyOperatorstrValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorstrValuesTime(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorstrValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorstrValuesTime_args(params); + try { + output.writeMessageBegin('findKeyOperatorstrValuesTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorstrValuesTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorstrValuesTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorstrValuesTime failed: unknown result'); + } + + findKeyOperatorstrValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorstrValuesTimestr(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorstrValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorstrValuesTimestr_args(params); + try { + output.writeMessageBegin('findKeyOperatorstrValuesTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorstrValuesTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorstrValuesTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorstrValuesTimestr failed: unknown result'); + } + + search (key, query, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_search(key, query, creds, transaction, environment); + }); + } + + send_search (key, query, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + query: query, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_search_args(params); + try { + output.writeMessageBegin('search', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_search (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_search_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('search failed: unknown result'); + } + + revertKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordsTime_args(params); + try { + output.writeMessageBegin('revertKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('revertKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + revertKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordTime_args(params); + try { + output.writeMessageBegin('revertKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('revertKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + revertKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordsTime_args(params); + try { + output.writeMessageBegin('revertKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('revertKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + revertKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordTime_args(params); + try { + output.writeMessageBegin('revertKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('revertKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + pingRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_pingRecords(records, creds, transaction, environment); + }); + } + + send_pingRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_pingRecords_args(params); + try { + output.writeMessageBegin('pingRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_pingRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_pingRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('pingRecords failed: unknown result'); + } + + pingRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_pingRecord(record, creds, transaction, environment); + }); + } + + send_pingRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_pingRecord_args(params); + try { + output.writeMessageBegin('pingRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_pingRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_pingRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('pingRecord failed: unknown result'); + } + + verifyAndSwap (key, expected, record, replacement, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyAndSwap(key, expected, record, replacement, creds, transaction, environment); + }); + } + + send_verifyAndSwap (key, expected, record, replacement, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + expected: expected, + record: record, + replacement: replacement, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyAndSwap_args(params); + try { + output.writeMessageBegin('verifyAndSwap', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyAndSwap (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyAndSwap_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyAndSwap failed: unknown result'); + } + + verifyOrSet (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyOrSet(key, value, record, creds, transaction, environment); + }); + } + + send_verifyOrSet (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyOrSet_args(params); + try { + output.writeMessageBegin('verifyOrSet', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyOrSet (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyOrSet_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + findOrAddKeyValue (key, value, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findOrAddKeyValue(key, value, creds, transaction, environment); + }); + } + + send_findOrAddKeyValue (key, value, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findOrAddKeyValue_args(params); + try { + output.writeMessageBegin('findOrAddKeyValue', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findOrAddKeyValue (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findOrAddKeyValue_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findOrAddKeyValue failed: unknown result'); + } + + findOrInsertCriteriaJson (criteria, json, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findOrInsertCriteriaJson(criteria, json, creds, transaction, environment); + }); + } + + send_findOrInsertCriteriaJson (criteria, json, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + json: json, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findOrInsertCriteriaJson_args(params); + try { + output.writeMessageBegin('findOrInsertCriteriaJson', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findOrInsertCriteriaJson (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findOrInsertCriteriaJson_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findOrInsertCriteriaJson failed: unknown result'); + } + + findOrInsertCclJson (ccl, json, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findOrInsertCclJson(ccl, json, creds, transaction, environment); + }); + } + + send_findOrInsertCclJson (ccl, json, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + json: json, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findOrInsertCclJson_args(params); + try { + output.writeMessageBegin('findOrInsertCclJson', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findOrInsertCclJson (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findOrInsertCclJson_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findOrInsertCclJson failed: unknown result'); + } + + sumKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_sumKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecord_args(params); + try { + output.writeMessageBegin('sumKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecord failed: unknown result'); + } + + sumKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordTime_args(params); + try { + output.writeMessageBegin('sumKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordTime failed: unknown result'); + } + + sumKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('sumKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordTimestr failed: unknown result'); + } + + sumKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_sumKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecords_args(params); + try { + output.writeMessageBegin('sumKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecords failed: unknown result'); + } + + sumKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordsTime_args(params); + try { + output.writeMessageBegin('sumKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordsTime failed: unknown result'); + } + + sumKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('sumKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordsTimestr failed: unknown result'); + } + + sumKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKey(key, creds, transaction, environment); + }); + } + + send_sumKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKey_args(params); + try { + output.writeMessageBegin('sumKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKey failed: unknown result'); + } + + sumKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyTime_args(params); + try { + output.writeMessageBegin('sumKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyTime failed: unknown result'); + } + + sumKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyTimestr_args(params); + try { + output.writeMessageBegin('sumKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyTimestr failed: unknown result'); + } + + sumKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_sumKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCriteria_args(params); + try { + output.writeMessageBegin('sumKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCriteria failed: unknown result'); + } + + sumKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('sumKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCriteriaTime failed: unknown result'); + } + + sumKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('sumKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCriteriaTimestr failed: unknown result'); + } + + sumKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_sumKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCcl_args(params); + try { + output.writeMessageBegin('sumKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCcl failed: unknown result'); + } + + sumKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCclTime_args(params); + try { + output.writeMessageBegin('sumKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCclTime failed: unknown result'); + } + + sumKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCclTimestr_args(params); + try { + output.writeMessageBegin('sumKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCclTimestr failed: unknown result'); + } + + averageKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_averageKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecord_args(params); + try { + output.writeMessageBegin('averageKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecord failed: unknown result'); + } + + averageKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordTime_args(params); + try { + output.writeMessageBegin('averageKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordTime failed: unknown result'); + } + + averageKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('averageKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordTimestr failed: unknown result'); + } + + averageKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_averageKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecords_args(params); + try { + output.writeMessageBegin('averageKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecords failed: unknown result'); + } + + averageKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordsTime_args(params); + try { + output.writeMessageBegin('averageKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordsTime failed: unknown result'); + } + + averageKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('averageKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordsTimestr failed: unknown result'); + } + + averageKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKey(key, creds, transaction, environment); + }); + } + + send_averageKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKey_args(params); + try { + output.writeMessageBegin('averageKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKey failed: unknown result'); + } + + averageKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyTime_args(params); + try { + output.writeMessageBegin('averageKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyTime failed: unknown result'); + } + + averageKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyTimestr_args(params); + try { + output.writeMessageBegin('averageKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyTimestr failed: unknown result'); + } + + averageKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_averageKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCriteria_args(params); + try { + output.writeMessageBegin('averageKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCriteria failed: unknown result'); + } + + averageKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('averageKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCriteriaTime failed: unknown result'); + } + + averageKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('averageKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCriteriaTimestr failed: unknown result'); + } + + averageKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_averageKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCcl_args(params); + try { + output.writeMessageBegin('averageKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCcl failed: unknown result'); + } + + averageKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCclTime_args(params); + try { + output.writeMessageBegin('averageKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCclTime failed: unknown result'); + } + + averageKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCclTimestr_args(params); + try { + output.writeMessageBegin('averageKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCclTimestr failed: unknown result'); + } + + countKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_countKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecord_args(params); + try { + output.writeMessageBegin('countKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecord failed: unknown result'); + } + + countKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordTime_args(params); + try { + output.writeMessageBegin('countKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordTime failed: unknown result'); + } + + countKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('countKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordTimestr failed: unknown result'); + } + + countKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_countKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecords_args(params); + try { + output.writeMessageBegin('countKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecords failed: unknown result'); + } + + countKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordsTime_args(params); + try { + output.writeMessageBegin('countKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordsTime failed: unknown result'); + } + + countKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('countKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordsTimestr failed: unknown result'); + } + + countKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKey(key, creds, transaction, environment); + }); + } + + send_countKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKey_args(params); + try { + output.writeMessageBegin('countKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKey failed: unknown result'); + } + + countKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_countKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyTime_args(params); + try { + output.writeMessageBegin('countKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyTime failed: unknown result'); + } + + countKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_countKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyTimestr_args(params); + try { + output.writeMessageBegin('countKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyTimestr failed: unknown result'); + } + + countKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_countKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCriteria_args(params); + try { + output.writeMessageBegin('countKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCriteria failed: unknown result'); + } + + countKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('countKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCriteriaTime failed: unknown result'); + } + + countKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('countKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCriteriaTimestr failed: unknown result'); + } + + countKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_countKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCcl_args(params); + try { + output.writeMessageBegin('countKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCcl failed: unknown result'); + } + + countKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCclTime_args(params); + try { + output.writeMessageBegin('countKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCclTime failed: unknown result'); + } + + countKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCclTimestr_args(params); + try { + output.writeMessageBegin('countKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCclTimestr failed: unknown result'); + } + + maxKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_maxKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecord_args(params); + try { + output.writeMessageBegin('maxKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecord failed: unknown result'); + } + + maxKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordTime_args(params); + try { + output.writeMessageBegin('maxKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordTime failed: unknown result'); + } + + maxKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('maxKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordTimestr failed: unknown result'); + } + + maxKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_maxKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecords_args(params); + try { + output.writeMessageBegin('maxKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecords failed: unknown result'); + } + + maxKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordsTime_args(params); + try { + output.writeMessageBegin('maxKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordsTime failed: unknown result'); + } + + maxKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('maxKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordsTimestr failed: unknown result'); + } + + maxKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_maxKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCriteria_args(params); + try { + output.writeMessageBegin('maxKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCriteria failed: unknown result'); + } + + maxKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('maxKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCriteriaTime failed: unknown result'); + } + + maxKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('maxKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCriteriaTimestr failed: unknown result'); + } + + maxKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_maxKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCcl_args(params); + try { + output.writeMessageBegin('maxKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCcl failed: unknown result'); + } + + maxKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCclTime_args(params); + try { + output.writeMessageBegin('maxKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCclTime failed: unknown result'); + } + + maxKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCclTimestr_args(params); + try { + output.writeMessageBegin('maxKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCclTimestr failed: unknown result'); + } + + maxKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKey(key, creds, transaction, environment); + }); + } + + send_maxKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKey_args(params); + try { + output.writeMessageBegin('maxKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKey failed: unknown result'); + } + + maxKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyTime_args(params); + try { + output.writeMessageBegin('maxKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyTime failed: unknown result'); + } + + maxKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyTimestr_args(params); + try { + output.writeMessageBegin('maxKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyTimestr failed: unknown result'); + } + + minKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_minKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecord_args(params); + try { + output.writeMessageBegin('minKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecord failed: unknown result'); + } + + minKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordTime_args(params); + try { + output.writeMessageBegin('minKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordTime failed: unknown result'); + } + + minKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('minKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordTimestr failed: unknown result'); + } + + minKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKey(key, creds, transaction, environment); + }); + } + + send_minKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKey_args(params); + try { + output.writeMessageBegin('minKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKey failed: unknown result'); + } + + minKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordsTime_args(params); + try { + output.writeMessageBegin('minKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordsTime failed: unknown result'); + } + + minKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('minKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordsTimestr failed: unknown result'); + } + + minKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_minKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCriteria_args(params); + try { + output.writeMessageBegin('minKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCriteria failed: unknown result'); + } + + minKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('minKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCriteriaTime failed: unknown result'); + } + + minKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('minKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCriteriaTimestr failed: unknown result'); + } + + minKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_minKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCcl_args(params); + try { + output.writeMessageBegin('minKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCcl failed: unknown result'); + } + + minKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCclTime_args(params); + try { + output.writeMessageBegin('minKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCclTime failed: unknown result'); + } + + minKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCclTimestr_args(params); + try { + output.writeMessageBegin('minKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCclTimestr failed: unknown result'); + } + + minKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_minKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyTime_args(params); + try { + output.writeMessageBegin('minKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyTime failed: unknown result'); + } + + minKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_minKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyTimestr_args(params); + try { + output.writeMessageBegin('minKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyTimestr failed: unknown result'); + } + + minKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_minKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecords_args(params); + try { + output.writeMessageBegin('minKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecords failed: unknown result'); + } + + navigateKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_navigateKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecord_args(params); + try { + output.writeMessageBegin('navigateKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecord failed: unknown result'); + } + + navigateKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordTime_args(params); + try { + output.writeMessageBegin('navigateKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordTime failed: unknown result'); + } + + navigateKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordTimestr failed: unknown result'); + } + + navigateKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_navigateKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecord_args(params); + try { + output.writeMessageBegin('navigateKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecord failed: unknown result'); + } + + navigateKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordTime_args(params); + try { + output.writeMessageBegin('navigateKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordTime failed: unknown result'); + } + + navigateKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordTimestr failed: unknown result'); + } + + navigateKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_navigateKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecords_args(params); + try { + output.writeMessageBegin('navigateKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecords failed: unknown result'); + } + + navigateKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_navigateKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecords_args(params); + try { + output.writeMessageBegin('navigateKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecords failed: unknown result'); + } + + navigateKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordsTime_args(params); + try { + output.writeMessageBegin('navigateKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordsTime failed: unknown result'); + } + + navigateKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordsTimestr failed: unknown result'); + } + + navigateKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordsTime_args(params); + try { + output.writeMessageBegin('navigateKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordsTime failed: unknown result'); + } + + navigateKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordsTimestr failed: unknown result'); + } + + navigateKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_navigateKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCcl_args(params); + try { + output.writeMessageBegin('navigateKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCcl failed: unknown result'); + } + + navigateKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCclTime_args(params); + try { + output.writeMessageBegin('navigateKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCclTime failed: unknown result'); + } + + navigateKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCclTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCclTimestr failed: unknown result'); + } + + navigateKeysCcl (keys, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCcl(keys, ccl, creds, transaction, environment); + }); + } + + send_navigateKeysCcl (keys, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCcl_args(params); + try { + output.writeMessageBegin('navigateKeysCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCcl failed: unknown result'); + } + + navigateKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCclTime_args(params); + try { + output.writeMessageBegin('navigateKeysCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCclTime failed: unknown result'); + } + + navigateKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCclTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCclTimestr failed: unknown result'); + } + + navigateKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_navigateKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCriteria_args(params); + try { + output.writeMessageBegin('navigateKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCriteria failed: unknown result'); + } + + navigateKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('navigateKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCriteriaTime failed: unknown result'); + } + + navigateKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCriteriaTimestr failed: unknown result'); + } + + navigateKeysCriteria (keys, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCriteria(keys, criteria, creds, transaction, environment); + }); + } + + send_navigateKeysCriteria (keys, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCriteria_args(params); + try { + output.writeMessageBegin('navigateKeysCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCriteria failed: unknown result'); + } + + navigateKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCriteriaTime_args(params); + try { + output.writeMessageBegin('navigateKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCriteriaTime failed: unknown result'); + } + + navigateKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCriteriaTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCriteriaTimestr failed: unknown result'); + } + + getServerEnvironment (creds, token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getServerEnvironment(creds, token, environment); + }); + } + + send_getServerEnvironment (creds, token, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + token: token, + environment: environment + }; + const args = new ConcourseService_getServerEnvironment_args(params); + try { + output.writeMessageBegin('getServerEnvironment', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getServerEnvironment (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getServerEnvironment_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getServerEnvironment failed: unknown result'); + } + + getServerVersion () { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getServerVersion(); + }); + } + + send_getServerVersion () { + const output = new this.pClass(this.output); + const args = new ConcourseService_getServerVersion_args(); + try { + output.writeMessageBegin('getServerVersion', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getServerVersion (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getServerVersion_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getServerVersion failed: unknown result'); + } + + time (creds, token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_time(creds, token, environment); + }); + } + + send_time (creds, token, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + token: token, + environment: environment + }; + const args = new ConcourseService_time_args(params); + try { + output.writeMessageBegin('time', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_time (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_time_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('time failed: unknown result'); + } + + timePhrase (phrase, creds, token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_timePhrase(phrase, creds, token, environment); + }); + } + + send_timePhrase (phrase, creds, token, environment) { + const output = new this.pClass(this.output); + const params = { + phrase: phrase, + creds: creds, + token: token, + environment: environment + }; + const args = new ConcourseService_timePhrase_args(params); + try { + output.writeMessageBegin('timePhrase', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_timePhrase (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_timePhrase_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('timePhrase failed: unknown result'); + } + + invokeManagement (method, params, creds) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_invokeManagement(method, params, creds); + }); + } + + send_invokeManagement (method, params, creds) { + const output = new this.pClass(this.output); + const params = { + method: method, + params: params, + creds: creds + }; + const args = new ConcourseService_invokeManagement_args(params); + try { + output.writeMessageBegin('invokeManagement', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_invokeManagement (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_invokeManagement_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('invokeManagement failed: unknown result'); + } +}; diff --git a/concourse-driver-node-js/src/thrift/ConcourseService.js.bak b/concourse-driver-node-js/src/thrift/ConcourseService.js.bak new file mode 100644 index 0000000000..28c9c36145 --- /dev/null +++ b/concourse-driver-node-js/src/thrift/ConcourseService.js.bak @@ -0,0 +1,101112 @@ +// +// Autogenerated by Thrift Compiler (0.12.0) +// +// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING +// +"use strict"; + +const thrift = require('thrift'); +const Thrift = thrift.Thrift; + +const data_ttypes = require('./data_types'); +const shared_ttypes = require('./shared_types'); +const exceptions_ttypes = require('./exceptions_types'); +const complex_ttypes = require('./complex_types'); + + +const ttypes = require('./concourse_types'); +//HELPER FUNCTIONS AND STRUCTURES + +const ConcourseService_abort_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_abort_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_abort_result = class { + constructor(args) { + this.ex = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_abort_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_addKeyValue_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValue_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_addKeyValue_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValue_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_addKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_addKeyValueRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValueRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_addKeyValueRecords_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31 = input.readListBegin(); + const _size0 = _rtmp31.size || 0; + for (let _i2 = 0; _i2 < _size0; ++_i2) { + let elem3 = null; + elem3 = input.readI64(); + this.records.push(elem3); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValueRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter4 in this.records) { + if (this.records.hasOwnProperty(iter4)) { + iter4 = this.records[iter4]; + output.writeI64(iter4); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_addKeyValueRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp36 = input.readMapBegin(); + const _size5 = _rtmp36.size || 0; + for (let _i7 = 0; _i7 < _size5; ++_i7) { + let key8 = null; + let val9 = null; + key8 = input.readI64(); + val9 = input.readBool(); + this.success[key8] = val9; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_addKeyValueRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); + for (let kiter10 in this.success) { + if (this.success.hasOwnProperty(kiter10)) { + let viter11 = this.success[kiter10]; + output.writeI64(kiter10); + output.writeBool(viter11); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp313 = input.readMapBegin(); + const _size12 = _rtmp313.size || 0; + for (let _i14 = 0; _i14 < _size12; ++_i14) { + let key15 = null; + let val16 = null; + key15 = input.readI64(); + val16 = input.readString(); + this.success[key15] = val16; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter17 in this.success) { + if (this.success.hasOwnProperty(kiter17)) { + let viter18 = this.success[kiter17]; + output.writeI64(kiter17); + output.writeString(viter18); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStart_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStart_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp320 = input.readMapBegin(); + const _size19 = _rtmp320.size || 0; + for (let _i21 = 0; _i21 < _size19; ++_i21) { + let key22 = null; + let val23 = null; + key22 = input.readI64(); + val23 = input.readString(); + this.success[key22] = val23; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStart_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter24 in this.success) { + if (this.success.hasOwnProperty(kiter24)) { + let viter25 = this.success[kiter24]; + output.writeI64(kiter24); + output.writeString(viter25); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStartstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp327 = input.readMapBegin(); + const _size26 = _rtmp327.size || 0; + for (let _i28 = 0; _i28 < _size26; ++_i28) { + let key29 = null; + let val30 = null; + key29 = input.readI64(); + val30 = input.readString(); + this.success[key29] = val30; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter31 in this.success) { + if (this.success.hasOwnProperty(kiter31)) { + let viter32 = this.success[kiter31]; + output.writeI64(kiter31); + output.writeString(viter32); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStartEnd_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.tend = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartEnd_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 3); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp334 = input.readMapBegin(); + const _size33 = _rtmp334.size || 0; + for (let _i35 = 0; _i35 < _size33; ++_i35) { + let key36 = null; + let val37 = null; + key36 = input.readI64(); + val37 = input.readString(); + this.success[key36] = val37; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartEnd_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter38 in this.success) { + if (this.success.hasOwnProperty(kiter38)) { + let viter39 = this.success[kiter38]; + output.writeI64(kiter38); + output.writeString(viter39); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStartstrEndstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.tend = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartstrEndstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 3); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp341 = input.readMapBegin(); + const _size40 = _rtmp341.size || 0; + for (let _i42 = 0; _i42 < _size40; ++_i42) { + let key43 = null; + let val44 = null; + key43 = input.readI64(); + val44 = input.readString(); + this.success[key43] = val44; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditRecordStartstrEndstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter45 in this.success) { + if (this.success.hasOwnProperty(kiter45)) { + let viter46 = this.success[kiter45]; + output.writeI64(kiter45); + output.writeString(viter46); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp348 = input.readMapBegin(); + const _size47 = _rtmp348.size || 0; + for (let _i49 = 0; _i49 < _size47; ++_i49) { + let key50 = null; + let val51 = null; + key50 = input.readI64(); + val51 = input.readString(); + this.success[key50] = val51; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter52 in this.success) { + if (this.success.hasOwnProperty(kiter52)) { + let viter53 = this.success[kiter52]; + output.writeI64(kiter52); + output.writeString(viter53); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStart_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp355 = input.readMapBegin(); + const _size54 = _rtmp355.size || 0; + for (let _i56 = 0; _i56 < _size54; ++_i56) { + let key57 = null; + let val58 = null; + key57 = input.readI64(); + val58 = input.readString(); + this.success[key57] = val58; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStart_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter59 in this.success) { + if (this.success.hasOwnProperty(kiter59)) { + let viter60 = this.success[kiter59]; + output.writeI64(kiter59); + output.writeString(viter60); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStartstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp362 = input.readMapBegin(); + const _size61 = _rtmp362.size || 0; + for (let _i63 = 0; _i63 < _size61; ++_i63) { + let key64 = null; + let val65 = null; + key64 = input.readI64(); + val65 = input.readString(); + this.success[key64] = val65; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter66 in this.success) { + if (this.success.hasOwnProperty(kiter66)) { + let viter67 = this.success[kiter66]; + output.writeI64(kiter66); + output.writeString(viter67); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStartEnd_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.I64) { + this.tend = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 4); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp369 = input.readMapBegin(); + const _size68 = _rtmp369.size || 0; + for (let _i70 = 0; _i70 < _size68; ++_i70) { + let key71 = null; + let val72 = null; + key71 = input.readI64(); + val72 = input.readString(); + this.success[key71] = val72; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartEnd_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter73 in this.success) { + if (this.success.hasOwnProperty(kiter73)) { + let viter74 = this.success[kiter73]; + output.writeI64(kiter73); + output.writeString(viter74); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.tend = input.readString(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 4); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_auditKeyRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp376 = input.readMapBegin(); + const _size75 = _rtmp376.size || 0; + for (let _i77 = 0; _i77 < _size75; ++_i77) { + let key78 = null; + let val79 = null; + key78 = input.readI64(); + val79 = input.readString(); + this.success[key78] = val79; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_auditKeyRecordStartstrEndstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); + for (let kiter80 in this.success) { + if (this.success.hasOwnProperty(kiter80)) { + let viter81 = this.success[kiter80]; + output.writeI64(kiter80); + output.writeString(viter81); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp383 = input.readMapBegin(); + const _size82 = _rtmp383.size || 0; + for (let _i84 = 0; _i84 < _size82; ++_i84) { + let key85 = null; + let val86 = null; + key85 = new data_ttypes.TObject(); + key85.read(input); + val86 = []; + const _rtmp388 = input.readSetBegin(); + const _size87 = _rtmp388.size || 0; + for (let _i89 = 0; _i89 < _size87; ++_i89) { + let elem90 = null; + elem90 = input.readI64(); + val86.push(elem90); + } + input.readSetEnd(); + this.success[key85] = val86; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKey_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter91 in this.success) { + if (this.success.hasOwnProperty(kiter91)) { + let viter92 = this.success[kiter91]; + kiter91.write(output); + output.writeSetBegin(Thrift.Type.I64, viter92.length); + for (let iter93 in viter92) { + if (viter92.hasOwnProperty(iter93)) { + iter93 = viter92[iter93]; + output.writeI64(iter93); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeys_args = class { + constructor(args) { + this.keys = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp395 = input.readListBegin(); + const _size94 = _rtmp395.size || 0; + for (let _i96 = 0; _i96 < _size94; ++_i96) { + let elem97 = null; + elem97 = input.readString(); + this.keys.push(elem97); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeys_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter98 in this.keys) { + if (this.keys.hasOwnProperty(iter98)) { + iter98 = this.keys[iter98]; + output.writeString(iter98); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeys_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3100 = input.readMapBegin(); + const _size99 = _rtmp3100.size || 0; + for (let _i101 = 0; _i101 < _size99; ++_i101) { + let key102 = null; + let val103 = null; + key102 = input.readString(); + val103 = {}; + const _rtmp3105 = input.readMapBegin(); + const _size104 = _rtmp3105.size || 0; + for (let _i106 = 0; _i106 < _size104; ++_i106) { + let key107 = null; + let val108 = null; + key107 = new data_ttypes.TObject(); + key107.read(input); + val108 = []; + const _rtmp3110 = input.readSetBegin(); + const _size109 = _rtmp3110.size || 0; + for (let _i111 = 0; _i111 < _size109; ++_i111) { + let elem112 = null; + elem112 = input.readI64(); + val108.push(elem112); + } + input.readSetEnd(); + val103[key107] = val108; + } + input.readMapEnd(); + this.success[key102] = val103; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeys_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter113 in this.success) { + if (this.success.hasOwnProperty(kiter113)) { + let viter114 = this.success[kiter113]; + output.writeString(kiter113); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(viter114)); + for (let kiter115 in viter114) { + if (viter114.hasOwnProperty(kiter115)) { + let viter116 = viter114[kiter115]; + kiter115.write(output); + output.writeSetBegin(Thrift.Type.I64, viter116.length); + for (let iter117 in viter116) { + if (viter116.hasOwnProperty(iter117)) { + iter117 = viter116[iter117]; + output.writeI64(iter117); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3119 = input.readMapBegin(); + const _size118 = _rtmp3119.size || 0; + for (let _i120 = 0; _i120 < _size118; ++_i120) { + let key121 = null; + let val122 = null; + key121 = new data_ttypes.TObject(); + key121.read(input); + val122 = []; + const _rtmp3124 = input.readSetBegin(); + const _size123 = _rtmp3124.size || 0; + for (let _i125 = 0; _i125 < _size123; ++_i125) { + let elem126 = null; + elem126 = input.readI64(); + val122.push(elem126); + } + input.readSetEnd(); + this.success[key121] = val122; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeyTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter127 in this.success) { + if (this.success.hasOwnProperty(kiter127)) { + let viter128 = this.success[kiter127]; + kiter127.write(output); + output.writeSetBegin(Thrift.Type.I64, viter128.length); + for (let iter129 in viter128) { + if (viter128.hasOwnProperty(iter129)) { + iter129 = viter128[iter129]; + output.writeI64(iter129); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3131 = input.readMapBegin(); + const _size130 = _rtmp3131.size || 0; + for (let _i132 = 0; _i132 < _size130; ++_i132) { + let key133 = null; + let val134 = null; + key133 = new data_ttypes.TObject(); + key133.read(input); + val134 = []; + const _rtmp3136 = input.readSetBegin(); + const _size135 = _rtmp3136.size || 0; + for (let _i137 = 0; _i137 < _size135; ++_i137) { + let elem138 = null; + elem138 = input.readI64(); + val134.push(elem138); + } + input.readSetEnd(); + this.success[key133] = val134; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeyTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter139 in this.success) { + if (this.success.hasOwnProperty(kiter139)) { + let viter140 = this.success[kiter139]; + kiter139.write(output); + output.writeSetBegin(Thrift.Type.I64, viter140.length); + for (let iter141 in viter140) { + if (viter140.hasOwnProperty(iter141)) { + iter141 = viter140[iter141]; + output.writeI64(iter141); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeysTime_args = class { + constructor(args) { + this.keys = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3143 = input.readListBegin(); + const _size142 = _rtmp3143.size || 0; + for (let _i144 = 0; _i144 < _size142; ++_i144) { + let elem145 = null; + elem145 = input.readString(); + this.keys.push(elem145); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeysTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter146 in this.keys) { + if (this.keys.hasOwnProperty(iter146)) { + iter146 = this.keys[iter146]; + output.writeString(iter146); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeysTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3148 = input.readMapBegin(); + const _size147 = _rtmp3148.size || 0; + for (let _i149 = 0; _i149 < _size147; ++_i149) { + let key150 = null; + let val151 = null; + key150 = input.readString(); + val151 = {}; + const _rtmp3153 = input.readMapBegin(); + const _size152 = _rtmp3153.size || 0; + for (let _i154 = 0; _i154 < _size152; ++_i154) { + let key155 = null; + let val156 = null; + key155 = new data_ttypes.TObject(); + key155.read(input); + val156 = []; + const _rtmp3158 = input.readSetBegin(); + const _size157 = _rtmp3158.size || 0; + for (let _i159 = 0; _i159 < _size157; ++_i159) { + let elem160 = null; + elem160 = input.readI64(); + val156.push(elem160); + } + input.readSetEnd(); + val151[key155] = val156; + } + input.readMapEnd(); + this.success[key150] = val151; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeysTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter161 in this.success) { + if (this.success.hasOwnProperty(kiter161)) { + let viter162 = this.success[kiter161]; + output.writeString(kiter161); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(viter162)); + for (let kiter163 in viter162) { + if (viter162.hasOwnProperty(kiter163)) { + let viter164 = viter162[kiter163]; + kiter163.write(output); + output.writeSetBegin(Thrift.Type.I64, viter164.length); + for (let iter165 in viter164) { + if (viter164.hasOwnProperty(iter165)) { + iter165 = viter164[iter165]; + output.writeI64(iter165); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeysTimestr_args = class { + constructor(args) { + this.keys = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3167 = input.readListBegin(); + const _size166 = _rtmp3167.size || 0; + for (let _i168 = 0; _i168 < _size166; ++_i168) { + let elem169 = null; + elem169 = input.readString(); + this.keys.push(elem169); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeysTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter170 in this.keys) { + if (this.keys.hasOwnProperty(iter170)) { + iter170 = this.keys[iter170]; + output.writeString(iter170); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_browseKeysTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3172 = input.readMapBegin(); + const _size171 = _rtmp3172.size || 0; + for (let _i173 = 0; _i173 < _size171; ++_i173) { + let key174 = null; + let val175 = null; + key174 = input.readString(); + val175 = {}; + const _rtmp3177 = input.readMapBegin(); + const _size176 = _rtmp3177.size || 0; + for (let _i178 = 0; _i178 < _size176; ++_i178) { + let key179 = null; + let val180 = null; + key179 = new data_ttypes.TObject(); + key179.read(input); + val180 = []; + const _rtmp3182 = input.readSetBegin(); + const _size181 = _rtmp3182.size || 0; + for (let _i183 = 0; _i183 < _size181; ++_i183) { + let elem184 = null; + elem184 = input.readI64(); + val180.push(elem184); + } + input.readSetEnd(); + val175[key179] = val180; + } + input.readMapEnd(); + this.success[key174] = val175; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_browseKeysTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter185 in this.success) { + if (this.success.hasOwnProperty(kiter185)) { + let viter186 = this.success[kiter185]; + output.writeString(kiter185); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(viter186)); + for (let kiter187 in viter186) { + if (viter186.hasOwnProperty(kiter187)) { + let viter188 = viter186[kiter187]; + kiter187.write(output); + output.writeSetBegin(Thrift.Type.I64, viter188.length); + for (let iter189 in viter188) { + if (viter188.hasOwnProperty(iter189)) { + iter189 = viter188[iter189]; + output.writeI64(iter189); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3191 = input.readMapBegin(); + const _size190 = _rtmp3191.size || 0; + for (let _i192 = 0; _i192 < _size190; ++_i192) { + let key193 = null; + let val194 = null; + key193 = input.readI64(); + val194 = []; + const _rtmp3196 = input.readSetBegin(); + const _size195 = _rtmp3196.size || 0; + for (let _i197 = 0; _i197 < _size195; ++_i197) { + let elem198 = null; + elem198 = new data_ttypes.TObject(); + elem198.read(input); + val194.push(elem198); + } + input.readSetEnd(); + this.success[key193] = val194; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter199 in this.success) { + if (this.success.hasOwnProperty(kiter199)) { + let viter200 = this.success[kiter199]; + output.writeI64(kiter199); + output.writeSetBegin(Thrift.Type.STRUCT, viter200.length); + for (let iter201 in viter200) { + if (viter200.hasOwnProperty(iter201)) { + iter201 = viter200[iter201]; + iter201.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStart_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3203 = input.readMapBegin(); + const _size202 = _rtmp3203.size || 0; + for (let _i204 = 0; _i204 < _size202; ++_i204) { + let key205 = null; + let val206 = null; + key205 = input.readI64(); + val206 = []; + const _rtmp3208 = input.readSetBegin(); + const _size207 = _rtmp3208.size || 0; + for (let _i209 = 0; _i209 < _size207; ++_i209) { + let elem210 = null; + elem210 = new data_ttypes.TObject(); + elem210.read(input); + val206.push(elem210); + } + input.readSetEnd(); + this.success[key205] = val206; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStart_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter211 in this.success) { + if (this.success.hasOwnProperty(kiter211)) { + let viter212 = this.success[kiter211]; + output.writeI64(kiter211); + output.writeSetBegin(Thrift.Type.STRUCT, viter212.length); + for (let iter213 in viter212) { + if (viter212.hasOwnProperty(iter213)) { + iter213 = viter212[iter213]; + iter213.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStartstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3215 = input.readMapBegin(); + const _size214 = _rtmp3215.size || 0; + for (let _i216 = 0; _i216 < _size214; ++_i216) { + let key217 = null; + let val218 = null; + key217 = input.readI64(); + val218 = []; + const _rtmp3220 = input.readSetBegin(); + const _size219 = _rtmp3220.size || 0; + for (let _i221 = 0; _i221 < _size219; ++_i221) { + let elem222 = null; + elem222 = new data_ttypes.TObject(); + elem222.read(input); + val218.push(elem222); + } + input.readSetEnd(); + this.success[key217] = val218; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter223 in this.success) { + if (this.success.hasOwnProperty(kiter223)) { + let viter224 = this.success[kiter223]; + output.writeI64(kiter223); + output.writeSetBegin(Thrift.Type.STRUCT, viter224.length); + for (let iter225 in viter224) { + if (viter224.hasOwnProperty(iter225)) { + iter225 = viter224[iter225]; + iter225.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStartEnd_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.I64) { + this.tend = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 4); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3227 = input.readMapBegin(); + const _size226 = _rtmp3227.size || 0; + for (let _i228 = 0; _i228 < _size226; ++_i228) { + let key229 = null; + let val230 = null; + key229 = input.readI64(); + val230 = []; + const _rtmp3232 = input.readSetBegin(); + const _size231 = _rtmp3232.size || 0; + for (let _i233 = 0; _i233 < _size231; ++_i233) { + let elem234 = null; + elem234 = new data_ttypes.TObject(); + elem234.read(input); + val230.push(elem234); + } + input.readSetEnd(); + this.success[key229] = val230; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartEnd_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter235 in this.success) { + if (this.success.hasOwnProperty(kiter235)) { + let viter236 = this.success[kiter235]; + output.writeI64(kiter235); + output.writeSetBegin(Thrift.Type.STRUCT, viter236.length); + for (let iter237 in viter236) { + if (viter236.hasOwnProperty(iter237)) { + iter237 = viter236[iter237]; + iter237.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.tend = input.readString(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 4); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_chronologizeKeyRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3239 = input.readMapBegin(); + const _size238 = _rtmp3239.size || 0; + for (let _i240 = 0; _i240 < _size238; ++_i240) { + let key241 = null; + let val242 = null; + key241 = input.readI64(); + val242 = []; + const _rtmp3244 = input.readSetBegin(); + const _size243 = _rtmp3244.size || 0; + for (let _i245 = 0; _i245 < _size243; ++_i245) { + let elem246 = null; + elem246 = new data_ttypes.TObject(); + elem246.read(input); + val242.push(elem246); + } + input.readSetEnd(); + this.success[key241] = val242; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstrEndstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter247 in this.success) { + if (this.success.hasOwnProperty(kiter247)) { + let viter248 = this.success[kiter247]; + output.writeI64(kiter247); + output.writeSetBegin(Thrift.Type.STRUCT, viter248.length); + for (let iter249 in viter248) { + if (viter248.hasOwnProperty(iter249)) { + iter249 = viter248[iter249]; + iter249.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearRecord_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3251 = input.readListBegin(); + const _size250 = _rtmp3251.size || 0; + for (let _i252 = 0; _i252 < _size250; ++_i252) { + let elem253 = null; + elem253 = input.readI64(); + this.records.push(elem253); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter254 in this.records) { + if (this.records.hasOwnProperty(iter254)) { + iter254 = this.records[iter254]; + output.writeI64(iter254); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearRecords_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeyRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeyRecord_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3256 = input.readListBegin(); + const _size255 = _rtmp3256.size || 0; + for (let _i257 = 0; _i257 < _size255; ++_i257) { + let elem258 = null; + elem258 = input.readString(); + this.keys.push(elem258); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter259 in this.keys) { + if (this.keys.hasOwnProperty(iter259)) { + iter259 = this.keys[iter259]; + output.writeString(iter259); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeysRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeysRecord_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3261 = input.readListBegin(); + const _size260 = _rtmp3261.size || 0; + for (let _i262 = 0; _i262 < _size260; ++_i262) { + let elem263 = null; + elem263 = input.readI64(); + this.records.push(elem263); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter264 in this.records) { + if (this.records.hasOwnProperty(iter264)) { + iter264 = this.records[iter264]; + output.writeI64(iter264); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeyRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeyRecords_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3266 = input.readListBegin(); + const _size265 = _rtmp3266.size || 0; + for (let _i267 = 0; _i267 < _size265; ++_i267) { + let elem268 = null; + elem268 = input.readString(); + this.keys.push(elem268); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3270 = input.readListBegin(); + const _size269 = _rtmp3270.size || 0; + for (let _i271 = 0; _i271 < _size269; ++_i271) { + let elem272 = null; + elem272 = input.readI64(); + this.records.push(elem272); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter273 in this.keys) { + if (this.keys.hasOwnProperty(iter273)) { + iter273 = this.keys[iter273]; + output.writeString(iter273); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter274 in this.records) { + if (this.records.hasOwnProperty(iter274)) { + iter274 = this.records[iter274]; + output.writeI64(iter274); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_clearKeysRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_clearKeysRecords_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_commit_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_commit_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_commit_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_commit_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describe_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describe_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describe_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3276 = input.readSetBegin(); + const _size275 = _rtmp3276.size || 0; + for (let _i277 = 0; _i277 < _size275; ++_i277) { + let elem278 = null; + elem278 = input.readString(); + this.success.push(elem278); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describe_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRING, this.success.length); + for (let iter279 in this.success) { + if (this.success.hasOwnProperty(iter279)) { + iter279 = this.success[iter279]; + output.writeString(iter279); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeTime_args = class { + constructor(args) { + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeTime_args'); + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 1); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3281 = input.readSetBegin(); + const _size280 = _rtmp3281.size || 0; + for (let _i282 = 0; _i282 < _size280; ++_i282) { + let elem283 = null; + elem283 = input.readString(); + this.success.push(elem283); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRING, this.success.length); + for (let iter284 in this.success) { + if (this.success.hasOwnProperty(iter284)) { + iter284 = this.success[iter284]; + output.writeString(iter284); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeTimestr_args = class { + constructor(args) { + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeTimestr_args'); + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 1); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3286 = input.readSetBegin(); + const _size285 = _rtmp3286.size || 0; + for (let _i287 = 0; _i287 < _size285; ++_i287) { + let elem288 = null; + elem288 = input.readString(); + this.success.push(elem288); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRING, this.success.length); + for (let iter289 in this.success) { + if (this.success.hasOwnProperty(iter289)) { + iter289 = this.success[iter289]; + output.writeString(iter289); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3291 = input.readSetBegin(); + const _size290 = _rtmp3291.size || 0; + for (let _i292 = 0; _i292 < _size290; ++_i292) { + let elem293 = null; + elem293 = input.readString(); + this.success.push(elem293); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRING, this.success.length); + for (let iter294 in this.success) { + if (this.success.hasOwnProperty(iter294)) { + iter294 = this.success[iter294]; + output.writeString(iter294); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordTime_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordTime_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3296 = input.readSetBegin(); + const _size295 = _rtmp3296.size || 0; + for (let _i297 = 0; _i297 < _size295; ++_i297) { + let elem298 = null; + elem298 = input.readString(); + this.success.push(elem298); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRING, this.success.length); + for (let iter299 in this.success) { + if (this.success.hasOwnProperty(iter299)) { + iter299 = this.success[iter299]; + output.writeString(iter299); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordTimestr_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordTimestr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3301 = input.readSetBegin(); + const _size300 = _rtmp3301.size || 0; + for (let _i302 = 0; _i302 < _size300; ++_i302) { + let elem303 = null; + elem303 = input.readString(); + this.success.push(elem303); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRING, this.success.length); + for (let iter304 in this.success) { + if (this.success.hasOwnProperty(iter304)) { + iter304 = this.success[iter304]; + output.writeString(iter304); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3306 = input.readListBegin(); + const _size305 = _rtmp3306.size || 0; + for (let _i307 = 0; _i307 < _size305; ++_i307) { + let elem308 = null; + elem308 = input.readI64(); + this.records.push(elem308); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter309 in this.records) { + if (this.records.hasOwnProperty(iter309)) { + iter309 = this.records[iter309]; + output.writeI64(iter309); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3311 = input.readMapBegin(); + const _size310 = _rtmp3311.size || 0; + for (let _i312 = 0; _i312 < _size310; ++_i312) { + let key313 = null; + let val314 = null; + key313 = input.readI64(); + val314 = []; + const _rtmp3316 = input.readSetBegin(); + const _size315 = _rtmp3316.size || 0; + for (let _i317 = 0; _i317 < _size315; ++_i317) { + let elem318 = null; + elem318 = input.readString(); + val314.push(elem318); + } + input.readSetEnd(); + this.success[key313] = val314; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter319 in this.success) { + if (this.success.hasOwnProperty(kiter319)) { + let viter320 = this.success[kiter319]; + output.writeI64(kiter319); + output.writeSetBegin(Thrift.Type.STRING, viter320.length); + for (let iter321 in viter320) { + if (viter320.hasOwnProperty(iter321)) { + iter321 = viter320[iter321]; + output.writeString(iter321); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordsTime_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3323 = input.readListBegin(); + const _size322 = _rtmp3323.size || 0; + for (let _i324 = 0; _i324 < _size322; ++_i324) { + let elem325 = null; + elem325 = input.readI64(); + this.records.push(elem325); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordsTime_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter326 in this.records) { + if (this.records.hasOwnProperty(iter326)) { + iter326 = this.records[iter326]; + output.writeI64(iter326); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3328 = input.readMapBegin(); + const _size327 = _rtmp3328.size || 0; + for (let _i329 = 0; _i329 < _size327; ++_i329) { + let key330 = null; + let val331 = null; + key330 = input.readI64(); + val331 = []; + const _rtmp3333 = input.readSetBegin(); + const _size332 = _rtmp3333.size || 0; + for (let _i334 = 0; _i334 < _size332; ++_i334) { + let elem335 = null; + elem335 = input.readString(); + val331.push(elem335); + } + input.readSetEnd(); + this.success[key330] = val331; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter336 in this.success) { + if (this.success.hasOwnProperty(kiter336)) { + let viter337 = this.success[kiter336]; + output.writeI64(kiter336); + output.writeSetBegin(Thrift.Type.STRING, viter337.length); + for (let iter338 in viter337) { + if (viter337.hasOwnProperty(iter338)) { + iter338 = viter337[iter338]; + output.writeString(iter338); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordsTimestr_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3340 = input.readListBegin(); + const _size339 = _rtmp3340.size || 0; + for (let _i341 = 0; _i341 < _size339; ++_i341) { + let elem342 = null; + elem342 = input.readI64(); + this.records.push(elem342); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordsTimestr_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter343 in this.records) { + if (this.records.hasOwnProperty(iter343)) { + iter343 = this.records[iter343]; + output.writeI64(iter343); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_describeRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3345 = input.readMapBegin(); + const _size344 = _rtmp3345.size || 0; + for (let _i346 = 0; _i346 < _size344; ++_i346) { + let key347 = null; + let val348 = null; + key347 = input.readI64(); + val348 = []; + const _rtmp3350 = input.readSetBegin(); + const _size349 = _rtmp3350.size || 0; + for (let _i351 = 0; _i351 < _size349; ++_i351) { + let elem352 = null; + elem352 = input.readString(); + val348.push(elem352); + } + input.readSetEnd(); + this.success[key347] = val348; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_describeRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter353 in this.success) { + if (this.success.hasOwnProperty(kiter353)) { + let viter354 = this.success[kiter353]; + output.writeI64(kiter353); + output.writeSetBegin(Thrift.Type.STRING, viter354.length); + for (let iter355 in viter354) { + if (viter354.hasOwnProperty(iter355)) { + iter355 = viter354[iter355]; + output.writeString(iter355); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStart_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStart_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3357 = input.readMapBegin(); + const _size356 = _rtmp3357.size || 0; + for (let _i358 = 0; _i358 < _size356; ++_i358) { + let key359 = null; + let val360 = null; + key359 = input.readString(); + val360 = {}; + const _rtmp3362 = input.readMapBegin(); + const _size361 = _rtmp3362.size || 0; + for (let _i363 = 0; _i363 < _size361; ++_i363) { + let key364 = null; + let val365 = null; + key364 = input.readI32(); + val365 = []; + const _rtmp3367 = input.readSetBegin(); + const _size366 = _rtmp3367.size || 0; + for (let _i368 = 0; _i368 < _size366; ++_i368) { + let elem369 = null; + elem369 = new data_ttypes.TObject(); + elem369.read(input); + val365.push(elem369); + } + input.readSetEnd(); + val360[key364] = val365; + } + input.readMapEnd(); + this.success[key359] = val360; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStart_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter370 in this.success) { + if (this.success.hasOwnProperty(kiter370)) { + let viter371 = this.success[kiter370]; + output.writeString(kiter370); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter371)); + for (let kiter372 in viter371) { + if (viter371.hasOwnProperty(kiter372)) { + let viter373 = viter371[kiter372]; + output.writeI32(kiter372); + output.writeSetBegin(Thrift.Type.STRUCT, viter373.length); + for (let iter374 in viter373) { + if (viter373.hasOwnProperty(iter374)) { + iter374 = viter373[iter374]; + iter374.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStartstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3376 = input.readMapBegin(); + const _size375 = _rtmp3376.size || 0; + for (let _i377 = 0; _i377 < _size375; ++_i377) { + let key378 = null; + let val379 = null; + key378 = input.readString(); + val379 = {}; + const _rtmp3381 = input.readMapBegin(); + const _size380 = _rtmp3381.size || 0; + for (let _i382 = 0; _i382 < _size380; ++_i382) { + let key383 = null; + let val384 = null; + key383 = input.readI32(); + val384 = []; + const _rtmp3386 = input.readSetBegin(); + const _size385 = _rtmp3386.size || 0; + for (let _i387 = 0; _i387 < _size385; ++_i387) { + let elem388 = null; + elem388 = new data_ttypes.TObject(); + elem388.read(input); + val384.push(elem388); + } + input.readSetEnd(); + val379[key383] = val384; + } + input.readMapEnd(); + this.success[key378] = val379; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter389 in this.success) { + if (this.success.hasOwnProperty(kiter389)) { + let viter390 = this.success[kiter389]; + output.writeString(kiter389); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter390)); + for (let kiter391 in viter390) { + if (viter390.hasOwnProperty(kiter391)) { + let viter392 = viter390[kiter391]; + output.writeI32(kiter391); + output.writeSetBegin(Thrift.Type.STRUCT, viter392.length); + for (let iter393 in viter392) { + if (viter392.hasOwnProperty(iter393)) { + iter393 = viter392[iter393]; + iter393.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStartEnd_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.tend = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartEnd_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 3); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3395 = input.readMapBegin(); + const _size394 = _rtmp3395.size || 0; + for (let _i396 = 0; _i396 < _size394; ++_i396) { + let key397 = null; + let val398 = null; + key397 = input.readString(); + val398 = {}; + const _rtmp3400 = input.readMapBegin(); + const _size399 = _rtmp3400.size || 0; + for (let _i401 = 0; _i401 < _size399; ++_i401) { + let key402 = null; + let val403 = null; + key402 = input.readI32(); + val403 = []; + const _rtmp3405 = input.readSetBegin(); + const _size404 = _rtmp3405.size || 0; + for (let _i406 = 0; _i406 < _size404; ++_i406) { + let elem407 = null; + elem407 = new data_ttypes.TObject(); + elem407.read(input); + val403.push(elem407); + } + input.readSetEnd(); + val398[key402] = val403; + } + input.readMapEnd(); + this.success[key397] = val398; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartEnd_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter408 in this.success) { + if (this.success.hasOwnProperty(kiter408)) { + let viter409 = this.success[kiter408]; + output.writeString(kiter408); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter409)); + for (let kiter410 in viter409) { + if (viter409.hasOwnProperty(kiter410)) { + let viter411 = viter409[kiter410]; + output.writeI32(kiter410); + output.writeSetBegin(Thrift.Type.STRUCT, viter411.length); + for (let iter412 in viter411) { + if (viter411.hasOwnProperty(iter412)) { + iter412 = viter411[iter412]; + iter412.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStartstrEndstr_args = class { + constructor(args) { + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.tend = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartstrEndstr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 3); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3414 = input.readMapBegin(); + const _size413 = _rtmp3414.size || 0; + for (let _i415 = 0; _i415 < _size413; ++_i415) { + let key416 = null; + let val417 = null; + key416 = input.readString(); + val417 = {}; + const _rtmp3419 = input.readMapBegin(); + const _size418 = _rtmp3419.size || 0; + for (let _i420 = 0; _i420 < _size418; ++_i420) { + let key421 = null; + let val422 = null; + key421 = input.readI32(); + val422 = []; + const _rtmp3424 = input.readSetBegin(); + const _size423 = _rtmp3424.size || 0; + for (let _i425 = 0; _i425 < _size423; ++_i425) { + let elem426 = null; + elem426 = new data_ttypes.TObject(); + elem426.read(input); + val422.push(elem426); + } + input.readSetEnd(); + val417[key421] = val422; + } + input.readMapEnd(); + this.success[key416] = val417; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffRecordStartstrEndstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter427 in this.success) { + if (this.success.hasOwnProperty(kiter427)) { + let viter428 = this.success[kiter427]; + output.writeString(kiter427); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter428)); + for (let kiter429 in viter428) { + if (viter428.hasOwnProperty(kiter429)) { + let viter430 = viter428[kiter429]; + output.writeI32(kiter429); + output.writeSetBegin(Thrift.Type.STRUCT, viter430.length); + for (let iter431 in viter430) { + if (viter430.hasOwnProperty(iter431)) { + iter431 = viter430[iter431]; + iter431.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStart_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3433 = input.readMapBegin(); + const _size432 = _rtmp3433.size || 0; + for (let _i434 = 0; _i434 < _size432; ++_i434) { + let key435 = null; + let val436 = null; + key435 = input.readI32(); + val436 = []; + const _rtmp3438 = input.readSetBegin(); + const _size437 = _rtmp3438.size || 0; + for (let _i439 = 0; _i439 < _size437; ++_i439) { + let elem440 = null; + elem440 = new data_ttypes.TObject(); + elem440.read(input); + val436.push(elem440); + } + input.readSetEnd(); + this.success[key435] = val436; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStart_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter441 in this.success) { + if (this.success.hasOwnProperty(kiter441)) { + let viter442 = this.success[kiter441]; + output.writeI32(kiter441); + output.writeSetBegin(Thrift.Type.STRUCT, viter442.length); + for (let iter443 in viter442) { + if (viter442.hasOwnProperty(iter443)) { + iter443 = viter442[iter443]; + iter443.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStartstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3445 = input.readMapBegin(); + const _size444 = _rtmp3445.size || 0; + for (let _i446 = 0; _i446 < _size444; ++_i446) { + let key447 = null; + let val448 = null; + key447 = input.readI32(); + val448 = []; + const _rtmp3450 = input.readSetBegin(); + const _size449 = _rtmp3450.size || 0; + for (let _i451 = 0; _i451 < _size449; ++_i451) { + let elem452 = null; + elem452 = new data_ttypes.TObject(); + elem452.read(input); + val448.push(elem452); + } + input.readSetEnd(); + this.success[key447] = val448; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter453 in this.success) { + if (this.success.hasOwnProperty(kiter453)) { + let viter454 = this.success[kiter453]; + output.writeI32(kiter453); + output.writeSetBegin(Thrift.Type.STRUCT, viter454.length); + for (let iter455 in viter454) { + if (viter454.hasOwnProperty(iter455)) { + iter455 = viter454[iter455]; + iter455.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStartEnd_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.I64) { + this.tend = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 3); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 4); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3457 = input.readMapBegin(); + const _size456 = _rtmp3457.size || 0; + for (let _i458 = 0; _i458 < _size456; ++_i458) { + let key459 = null; + let val460 = null; + key459 = input.readI32(); + val460 = []; + const _rtmp3462 = input.readSetBegin(); + const _size461 = _rtmp3462.size || 0; + for (let _i463 = 0; _i463 < _size461; ++_i463) { + let elem464 = null; + elem464 = new data_ttypes.TObject(); + elem464.read(input); + val460.push(elem464); + } + input.readSetEnd(); + this.success[key459] = val460; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartEnd_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter465 in this.success) { + if (this.success.hasOwnProperty(kiter465)) { + let viter466 = this.success[kiter465]; + output.writeI32(kiter465); + output.writeSetBegin(Thrift.Type.STRUCT, viter466.length); + for (let iter467 in viter466) { + if (viter466.hasOwnProperty(iter467)) { + iter467 = viter466[iter467]; + iter467.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.tend = input.readString(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 3); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 4); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyRecordStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3469 = input.readMapBegin(); + const _size468 = _rtmp3469.size || 0; + for (let _i470 = 0; _i470 < _size468; ++_i470) { + let key471 = null; + let val472 = null; + key471 = input.readI32(); + val472 = []; + const _rtmp3474 = input.readSetBegin(); + const _size473 = _rtmp3474.size || 0; + for (let _i475 = 0; _i475 < _size473; ++_i475) { + let elem476 = null; + elem476 = new data_ttypes.TObject(); + elem476.read(input); + val472.push(elem476); + } + input.readSetEnd(); + this.success[key471] = val472; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyRecordStartstrEndstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter477 in this.success) { + if (this.success.hasOwnProperty(kiter477)) { + let viter478 = this.success[kiter477]; + output.writeI32(kiter477); + output.writeSetBegin(Thrift.Type.STRUCT, viter478.length); + for (let iter479 in viter478) { + if (viter478.hasOwnProperty(iter479)) { + iter479 = viter478[iter479]; + iter479.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStart_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStart_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStart_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3481 = input.readMapBegin(); + const _size480 = _rtmp3481.size || 0; + for (let _i482 = 0; _i482 < _size480; ++_i482) { + let key483 = null; + let val484 = null; + key483 = new data_ttypes.TObject(); + key483.read(input); + val484 = {}; + const _rtmp3486 = input.readMapBegin(); + const _size485 = _rtmp3486.size || 0; + for (let _i487 = 0; _i487 < _size485; ++_i487) { + let key488 = null; + let val489 = null; + key488 = input.readI32(); + val489 = []; + const _rtmp3491 = input.readSetBegin(); + const _size490 = _rtmp3491.size || 0; + for (let _i492 = 0; _i492 < _size490; ++_i492) { + let elem493 = null; + elem493 = input.readI64(); + val489.push(elem493); + } + input.readSetEnd(); + val484[key488] = val489; + } + input.readMapEnd(); + this.success[key483] = val484; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStart_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter494 in this.success) { + if (this.success.hasOwnProperty(kiter494)) { + let viter495 = this.success[kiter494]; + kiter494.write(output); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter495)); + for (let kiter496 in viter495) { + if (viter495.hasOwnProperty(kiter496)) { + let viter497 = viter495[kiter496]; + output.writeI32(kiter496); + output.writeSetBegin(Thrift.Type.I64, viter497.length); + for (let iter498 in viter497) { + if (viter497.hasOwnProperty(iter498)) { + iter498 = viter497[iter498]; + output.writeI64(iter498); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStartstr_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStartstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3500 = input.readMapBegin(); + const _size499 = _rtmp3500.size || 0; + for (let _i501 = 0; _i501 < _size499; ++_i501) { + let key502 = null; + let val503 = null; + key502 = new data_ttypes.TObject(); + key502.read(input); + val503 = {}; + const _rtmp3505 = input.readMapBegin(); + const _size504 = _rtmp3505.size || 0; + for (let _i506 = 0; _i506 < _size504; ++_i506) { + let key507 = null; + let val508 = null; + key507 = input.readI32(); + val508 = []; + const _rtmp3510 = input.readSetBegin(); + const _size509 = _rtmp3510.size || 0; + for (let _i511 = 0; _i511 < _size509; ++_i511) { + let elem512 = null; + elem512 = input.readI64(); + val508.push(elem512); + } + input.readSetEnd(); + val503[key507] = val508; + } + input.readMapEnd(); + this.success[key502] = val503; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter513 in this.success) { + if (this.success.hasOwnProperty(kiter513)) { + let viter514 = this.success[kiter513]; + kiter513.write(output); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter514)); + for (let kiter515 in viter514) { + if (viter514.hasOwnProperty(kiter515)) { + let viter516 = viter514[kiter515]; + output.writeI32(kiter515); + output.writeSetBegin(Thrift.Type.I64, viter516.length); + for (let iter517 in viter516) { + if (viter516.hasOwnProperty(iter517)) { + iter517 = viter516[iter517]; + output.writeI64(iter517); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStartEnd_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.start = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.tend = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartEnd_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.I64, 2); + output.writeI64(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.I64, 3); + output.writeI64(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStartEnd_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3519 = input.readMapBegin(); + const _size518 = _rtmp3519.size || 0; + for (let _i520 = 0; _i520 < _size518; ++_i520) { + let key521 = null; + let val522 = null; + key521 = new data_ttypes.TObject(); + key521.read(input); + val522 = {}; + const _rtmp3524 = input.readMapBegin(); + const _size523 = _rtmp3524.size || 0; + for (let _i525 = 0; _i525 < _size523; ++_i525) { + let key526 = null; + let val527 = null; + key526 = input.readI32(); + val527 = []; + const _rtmp3529 = input.readSetBegin(); + const _size528 = _rtmp3529.size || 0; + for (let _i530 = 0; _i530 < _size528; ++_i530) { + let elem531 = null; + elem531 = input.readI64(); + val527.push(elem531); + } + input.readSetEnd(); + val522[key526] = val527; + } + input.readMapEnd(); + this.success[key521] = val522; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartEnd_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter532 in this.success) { + if (this.success.hasOwnProperty(kiter532)) { + let viter533 = this.success[kiter532]; + kiter532.write(output); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter533)); + for (let kiter534 in viter533) { + if (viter533.hasOwnProperty(kiter534)) { + let viter535 = viter533[kiter534]; + output.writeI32(kiter534); + output.writeSetBegin(Thrift.Type.I64, viter535.length); + for (let iter536 in viter535) { + if (viter535.hasOwnProperty(iter536)) { + iter536 = viter535[iter536]; + output.writeI64(iter536); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStartstrEndstr_args = class { + constructor(args) { + this.key = null; + this.start = null; + this.tend = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.start !== undefined && args.start !== null) { + this.start = args.start; + } + if (args.tend !== undefined && args.tend !== null) { + this.tend = args.tend; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.start = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.tend = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartstrEndstr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.start !== null && this.start !== undefined) { + output.writeFieldBegin('start', Thrift.Type.STRING, 2); + output.writeString(this.start); + output.writeFieldEnd(); + } + if (this.tend !== null && this.tend !== undefined) { + output.writeFieldBegin('tend', Thrift.Type.STRING, 3); + output.writeString(this.tend); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_diffKeyStartstrEndstr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3538 = input.readMapBegin(); + const _size537 = _rtmp3538.size || 0; + for (let _i539 = 0; _i539 < _size537; ++_i539) { + let key540 = null; + let val541 = null; + key540 = new data_ttypes.TObject(); + key540.read(input); + val541 = {}; + const _rtmp3543 = input.readMapBegin(); + const _size542 = _rtmp3543.size || 0; + for (let _i544 = 0; _i544 < _size542; ++_i544) { + let key545 = null; + let val546 = null; + key545 = input.readI32(); + val546 = []; + const _rtmp3548 = input.readSetBegin(); + const _size547 = _rtmp3548.size || 0; + for (let _i549 = 0; _i549 < _size547; ++_i549) { + let elem550 = null; + elem550 = input.readI64(); + val546.push(elem550); + } + input.readSetEnd(); + val541[key545] = val546; + } + input.readMapEnd(); + this.success[key540] = val541; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_diffKeyStartstrEndstr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter551 in this.success) { + if (this.success.hasOwnProperty(kiter551)) { + let viter552 = this.success[kiter551]; + kiter551.write(output); + output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter552)); + for (let kiter553 in viter552) { + if (viter552.hasOwnProperty(kiter553)) { + let viter554 = viter552[kiter553]; + output.writeI32(kiter553); + output.writeSetBegin(Thrift.Type.I64, viter554.length); + for (let iter555 in viter554) { + if (viter554.hasOwnProperty(iter555)) { + iter555 = viter554[iter555]; + output.writeI64(iter555); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_invokePlugin_args = class { + constructor(args) { + this.id = null; + this.method = null; + this.params = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.id !== undefined && args.id !== null) { + this.id = args.id; + } + if (args.method !== undefined && args.method !== null) { + this.method = args.method; + } + if (args.params !== undefined && args.params !== null) { + this.params = Thrift.copyList(args.params, [complex_ttypes.ComplexTObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.id = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.method = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.params = []; + const _rtmp3557 = input.readListBegin(); + const _size556 = _rtmp3557.size || 0; + for (let _i558 = 0; _i558 < _size556; ++_i558) { + let elem559 = null; + elem559 = new complex_ttypes.ComplexTObject(); + elem559.read(input); + this.params.push(elem559); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_invokePlugin_args'); + if (this.id !== null && this.id !== undefined) { + output.writeFieldBegin('id', Thrift.Type.STRING, 1); + output.writeString(this.id); + output.writeFieldEnd(); + } + if (this.method !== null && this.method !== undefined) { + output.writeFieldBegin('method', Thrift.Type.STRING, 2); + output.writeString(this.method); + output.writeFieldEnd(); + } + if (this.params !== null && this.params !== undefined) { + output.writeFieldBegin('params', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.params.length); + for (let iter560 in this.params) { + if (this.params.hasOwnProperty(iter560)) { + iter560 = this.params[iter560]; + iter560.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_invokePlugin_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new complex_ttypes.ComplexTObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new complex_ttypes.ComplexTObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_invokePlugin_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_login_args = class { + constructor(args) { + this.username = null; + this.password = null; + this.environment = null; + if (args) { + if (args.username !== undefined && args.username !== null) { + this.username = args.username; + } + if (args.password !== undefined && args.password !== null) { + this.password = args.password; + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.username = input.readBinary(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.password = input.readBinary(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_login_args'); + if (this.username !== null && this.username !== undefined) { + output.writeFieldBegin('username', Thrift.Type.STRING, 1); + output.writeBinary(this.username); + output.writeFieldEnd(); + } + if (this.password !== null && this.password !== undefined) { + output.writeFieldBegin('password', Thrift.Type.STRING, 2); + output.writeBinary(this.password); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_login_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex2 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new shared_ttypes.AccessToken(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new shared_ttypes.AccessToken(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.PermissionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_login_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_logout_args = class { + constructor(args) { + this.token = null; + this.environment = null; + if (args) { + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.AccessToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.token = new shared_ttypes.AccessToken(); + this.token.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_logout_args'); + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 1); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 2); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_logout_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex2 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.PermissionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_logout_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_stage_args = class { + constructor(args) { + this.token = null; + this.environment = null; + if (args) { + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.AccessToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.token = new shared_ttypes.AccessToken(); + this.token.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_stage_args'); + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 1); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 2); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_stage_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex2 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new shared_ttypes.TransactionToken(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new shared_ttypes.TransactionToken(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.PermissionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_stage_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_insertJson_args = class { + constructor(args) { + this.json = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.json = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJson_args'); + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 1); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_insertJson_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3562 = input.readSetBegin(); + const _size561 = _rtmp3562.size || 0; + for (let _i563 = 0; _i563 < _size561; ++_i563) { + let elem564 = null; + elem564 = input.readI64(); + this.success.push(elem564); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJson_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter565 in this.success) { + if (this.success.hasOwnProperty(iter565)) { + iter565 = this.success[iter565]; + output.writeI64(iter565); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + if (this.ex5 !== null && this.ex5 !== undefined) { + output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); + this.ex5.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_insertJsonRecord_args = class { + constructor(args) { + this.json = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.json = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJsonRecord_args'); + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 1); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_insertJsonRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJsonRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + if (this.ex5 !== null && this.ex5 !== undefined) { + output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); + this.ex5.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_insertJsonRecords_args = class { + constructor(args) { + this.json = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.json = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3567 = input.readListBegin(); + const _size566 = _rtmp3567.size || 0; + for (let _i568 = 0; _i568 < _size566; ++_i568) { + let elem569 = null; + elem569 = input.readI64(); + this.records.push(elem569); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJsonRecords_args'); + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 1); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter570 in this.records) { + if (this.records.hasOwnProperty(iter570)) { + iter570 = this.records[iter570]; + output.writeI64(iter570); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_insertJsonRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3572 = input.readMapBegin(); + const _size571 = _rtmp3572.size || 0; + for (let _i573 = 0; _i573 < _size571; ++_i573) { + let key574 = null; + let val575 = null; + key574 = input.readI64(); + val575 = input.readBool(); + this.success[key574] = val575; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_insertJsonRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); + for (let kiter576 in this.success) { + if (this.success.hasOwnProperty(kiter576)) { + let viter577 = this.success[kiter576]; + output.writeI64(kiter576); + output.writeBool(viter577); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + if (this.ex5 !== null && this.ex5 !== undefined) { + output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); + this.ex5.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_removeKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_removeKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_removeKeyValueRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_removeKeyValueRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_removeKeyValueRecords_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3579 = input.readListBegin(); + const _size578 = _rtmp3579.size || 0; + for (let _i580 = 0; _i580 < _size578; ++_i580) { + let elem581 = null; + elem581 = input.readI64(); + this.records.push(elem581); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_removeKeyValueRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter582 in this.records) { + if (this.records.hasOwnProperty(iter582)) { + iter582 = this.records[iter582]; + output.writeI64(iter582); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_removeKeyValueRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3584 = input.readMapBegin(); + const _size583 = _rtmp3584.size || 0; + for (let _i585 = 0; _i585 < _size583; ++_i585) { + let key586 = null; + let val587 = null; + key586 = input.readI64(); + val587 = input.readBool(); + this.success[key586] = val587; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_removeKeyValueRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); + for (let kiter588 in this.success) { + if (this.success.hasOwnProperty(kiter588)) { + let viter589 = this.success[kiter588]; + output.writeI64(kiter588); + output.writeBool(viter589); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_setKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_setKeyValueRecord_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValueRecord_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_setKeyValue_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValue_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_setKeyValue_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValue_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_setKeyValueRecords_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3591 = input.readListBegin(); + const _size590 = _rtmp3591.size || 0; + for (let _i592 = 0; _i592 < _size590; ++_i592) { + let elem593 = null; + elem593 = input.readI64(); + this.records.push(elem593); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValueRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter594 in this.records) { + if (this.records.hasOwnProperty(iter594)) { + iter594 = this.records[iter594]; + output.writeI64(iter594); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_setKeyValueRecords_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_setKeyValueRecords_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_reconcileKeyRecordValues_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.values = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.SET) { + this.values = []; + const _rtmp3596 = input.readSetBegin(); + const _size595 = _rtmp3596.size || 0; + for (let _i597 = 0; _i597 < _size595; ++_i597) { + let elem598 = null; + elem598 = new data_ttypes.TObject(); + elem598.read(input); + this.values.push(elem598); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_reconcileKeyRecordValues_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.SET, 3); + output.writeSetBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter599 in this.values) { + if (this.values.hasOwnProperty(iter599)) { + iter599 = this.values[iter599]; + iter599.write(output); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_reconcileKeyRecordValues_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_reconcileKeyRecordValues_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_inventory_args = class { + constructor(args) { + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_inventory_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_inventory_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3601 = input.readSetBegin(); + const _size600 = _rtmp3601.size || 0; + for (let _i602 = 0; _i602 < _size600; ++_i602) { + let elem603 = null; + elem603 = input.readI64(); + this.success.push(elem603); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_inventory_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter604 in this.success) { + if (this.success.hasOwnProperty(iter604)) { + iter604 = this.success[iter604]; + output.writeI64(iter604); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3606 = input.readMapBegin(); + const _size605 = _rtmp3606.size || 0; + for (let _i607 = 0; _i607 < _size605; ++_i607) { + let key608 = null; + let val609 = null; + key608 = input.readString(); + val609 = []; + const _rtmp3611 = input.readSetBegin(); + const _size610 = _rtmp3611.size || 0; + for (let _i612 = 0; _i612 < _size610; ++_i612) { + let elem613 = null; + elem613 = new data_ttypes.TObject(); + elem613.read(input); + val609.push(elem613); + } + input.readSetEnd(); + this.success[key608] = val609; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter614 in this.success) { + if (this.success.hasOwnProperty(kiter614)) { + let viter615 = this.success[kiter614]; + output.writeString(kiter614); + output.writeSetBegin(Thrift.Type.STRUCT, viter615.length); + for (let iter616 in viter615) { + if (viter615.hasOwnProperty(iter616)) { + iter616 = viter615[iter616]; + iter616.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3618 = input.readListBegin(); + const _size617 = _rtmp3618.size || 0; + for (let _i619 = 0; _i619 < _size617; ++_i619) { + let elem620 = null; + elem620 = input.readI64(); + this.records.push(elem620); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter621 in this.records) { + if (this.records.hasOwnProperty(iter621)) { + iter621 = this.records[iter621]; + output.writeI64(iter621); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3623 = input.readMapBegin(); + const _size622 = _rtmp3623.size || 0; + for (let _i624 = 0; _i624 < _size622; ++_i624) { + let key625 = null; + let val626 = null; + key625 = input.readI64(); + val626 = {}; + const _rtmp3628 = input.readMapBegin(); + const _size627 = _rtmp3628.size || 0; + for (let _i629 = 0; _i629 < _size627; ++_i629) { + let key630 = null; + let val631 = null; + key630 = input.readString(); + val631 = []; + const _rtmp3633 = input.readSetBegin(); + const _size632 = _rtmp3633.size || 0; + for (let _i634 = 0; _i634 < _size632; ++_i634) { + let elem635 = null; + elem635 = new data_ttypes.TObject(); + elem635.read(input); + val631.push(elem635); + } + input.readSetEnd(); + val626[key630] = val631; + } + input.readMapEnd(); + this.success[key625] = val626; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter636 in this.success) { + if (this.success.hasOwnProperty(kiter636)) { + let viter637 = this.success[kiter636]; + output.writeI64(kiter636); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter637)); + for (let kiter638 in viter637) { + if (viter637.hasOwnProperty(kiter638)) { + let viter639 = viter637[kiter638]; + output.writeString(kiter638); + output.writeSetBegin(Thrift.Type.STRUCT, viter639.length); + for (let iter640 in viter639) { + if (viter639.hasOwnProperty(iter640)) { + iter640 = viter639[iter640]; + iter640.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordTime_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordTime_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3642 = input.readMapBegin(); + const _size641 = _rtmp3642.size || 0; + for (let _i643 = 0; _i643 < _size641; ++_i643) { + let key644 = null; + let val645 = null; + key644 = input.readString(); + val645 = []; + const _rtmp3647 = input.readSetBegin(); + const _size646 = _rtmp3647.size || 0; + for (let _i648 = 0; _i648 < _size646; ++_i648) { + let elem649 = null; + elem649 = new data_ttypes.TObject(); + elem649.read(input); + val645.push(elem649); + } + input.readSetEnd(); + this.success[key644] = val645; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter650 in this.success) { + if (this.success.hasOwnProperty(kiter650)) { + let viter651 = this.success[kiter650]; + output.writeString(kiter650); + output.writeSetBegin(Thrift.Type.STRUCT, viter651.length); + for (let iter652 in viter651) { + if (viter651.hasOwnProperty(iter652)) { + iter652 = viter651[iter652]; + iter652.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordTimestr_args = class { + constructor(args) { + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordTimestr_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3654 = input.readMapBegin(); + const _size653 = _rtmp3654.size || 0; + for (let _i655 = 0; _i655 < _size653; ++_i655) { + let key656 = null; + let val657 = null; + key656 = input.readString(); + val657 = []; + const _rtmp3659 = input.readSetBegin(); + const _size658 = _rtmp3659.size || 0; + for (let _i660 = 0; _i660 < _size658; ++_i660) { + let elem661 = null; + elem661 = new data_ttypes.TObject(); + elem661.read(input); + val657.push(elem661); + } + input.readSetEnd(); + this.success[key656] = val657; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter662 in this.success) { + if (this.success.hasOwnProperty(kiter662)) { + let viter663 = this.success[kiter662]; + output.writeString(kiter662); + output.writeSetBegin(Thrift.Type.STRUCT, viter663.length); + for (let iter664 in viter663) { + if (viter663.hasOwnProperty(iter664)) { + iter664 = viter663[iter664]; + iter664.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordsTime_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3666 = input.readListBegin(); + const _size665 = _rtmp3666.size || 0; + for (let _i667 = 0; _i667 < _size665; ++_i667) { + let elem668 = null; + elem668 = input.readI64(); + this.records.push(elem668); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordsTime_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter669 in this.records) { + if (this.records.hasOwnProperty(iter669)) { + iter669 = this.records[iter669]; + output.writeI64(iter669); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3671 = input.readMapBegin(); + const _size670 = _rtmp3671.size || 0; + for (let _i672 = 0; _i672 < _size670; ++_i672) { + let key673 = null; + let val674 = null; + key673 = input.readI64(); + val674 = {}; + const _rtmp3676 = input.readMapBegin(); + const _size675 = _rtmp3676.size || 0; + for (let _i677 = 0; _i677 < _size675; ++_i677) { + let key678 = null; + let val679 = null; + key678 = input.readString(); + val679 = []; + const _rtmp3681 = input.readSetBegin(); + const _size680 = _rtmp3681.size || 0; + for (let _i682 = 0; _i682 < _size680; ++_i682) { + let elem683 = null; + elem683 = new data_ttypes.TObject(); + elem683.read(input); + val679.push(elem683); + } + input.readSetEnd(); + val674[key678] = val679; + } + input.readMapEnd(); + this.success[key673] = val674; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter684 in this.success) { + if (this.success.hasOwnProperty(kiter684)) { + let viter685 = this.success[kiter684]; + output.writeI64(kiter684); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter685)); + for (let kiter686 in viter685) { + if (viter685.hasOwnProperty(kiter686)) { + let viter687 = viter685[kiter686]; + output.writeString(kiter686); + output.writeSetBegin(Thrift.Type.STRUCT, viter687.length); + for (let iter688 in viter687) { + if (viter687.hasOwnProperty(iter688)) { + iter688 = viter687[iter688]; + iter688.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordsTimestr_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3690 = input.readListBegin(); + const _size689 = _rtmp3690.size || 0; + for (let _i691 = 0; _i691 < _size689; ++_i691) { + let elem692 = null; + elem692 = input.readI64(); + this.records.push(elem692); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordsTimestr_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter693 in this.records) { + if (this.records.hasOwnProperty(iter693)) { + iter693 = this.records[iter693]; + output.writeI64(iter693); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3695 = input.readMapBegin(); + const _size694 = _rtmp3695.size || 0; + for (let _i696 = 0; _i696 < _size694; ++_i696) { + let key697 = null; + let val698 = null; + key697 = input.readI64(); + val698 = {}; + const _rtmp3700 = input.readMapBegin(); + const _size699 = _rtmp3700.size || 0; + for (let _i701 = 0; _i701 < _size699; ++_i701) { + let key702 = null; + let val703 = null; + key702 = input.readString(); + val703 = []; + const _rtmp3705 = input.readSetBegin(); + const _size704 = _rtmp3705.size || 0; + for (let _i706 = 0; _i706 < _size704; ++_i706) { + let elem707 = null; + elem707 = new data_ttypes.TObject(); + elem707.read(input); + val703.push(elem707); + } + input.readSetEnd(); + val698[key702] = val703; + } + input.readMapEnd(); + this.success[key697] = val698; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter708 in this.success) { + if (this.success.hasOwnProperty(kiter708)) { + let viter709 = this.success[kiter708]; + output.writeI64(kiter708); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter709)); + for (let kiter710 in viter709) { + if (viter709.hasOwnProperty(kiter710)) { + let viter711 = viter709[kiter710]; + output.writeString(kiter710); + output.writeSetBegin(Thrift.Type.STRUCT, viter711.length); + for (let iter712 in viter711) { + if (viter711.hasOwnProperty(iter712)) { + iter712 = viter711[iter712]; + iter712.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3714 = input.readSetBegin(); + const _size713 = _rtmp3714.size || 0; + for (let _i715 = 0; _i715 < _size713; ++_i715) { + let elem716 = null; + elem716 = new data_ttypes.TObject(); + elem716.read(input); + this.success.push(elem716); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRUCT, this.success.length); + for (let iter717 in this.success) { + if (this.success.hasOwnProperty(iter717)) { + iter717 = this.success[iter717]; + iter717.write(output); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3719 = input.readSetBegin(); + const _size718 = _rtmp3719.size || 0; + for (let _i720 = 0; _i720 < _size718; ++_i720) { + let elem721 = null; + elem721 = new data_ttypes.TObject(); + elem721.read(input); + this.success.push(elem721); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRUCT, this.success.length); + for (let iter722 in this.success) { + if (this.success.hasOwnProperty(iter722)) { + iter722 = this.success[iter722]; + iter722.write(output); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp3724 = input.readSetBegin(); + const _size723 = _rtmp3724.size || 0; + for (let _i725 = 0; _i725 < _size723; ++_i725) { + let elem726 = null; + elem726 = new data_ttypes.TObject(); + elem726.read(input); + this.success.push(elem726); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.STRUCT, this.success.length); + for (let iter727 in this.success) { + if (this.success.hasOwnProperty(iter727)) { + iter727 = this.success[iter727]; + iter727.write(output); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3729 = input.readListBegin(); + const _size728 = _rtmp3729.size || 0; + for (let _i730 = 0; _i730 < _size728; ++_i730) { + let elem731 = null; + elem731 = input.readString(); + this.keys.push(elem731); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter732 in this.keys) { + if (this.keys.hasOwnProperty(iter732)) { + iter732 = this.keys[iter732]; + output.writeString(iter732); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3734 = input.readMapBegin(); + const _size733 = _rtmp3734.size || 0; + for (let _i735 = 0; _i735 < _size733; ++_i735) { + let key736 = null; + let val737 = null; + key736 = input.readString(); + val737 = []; + const _rtmp3739 = input.readSetBegin(); + const _size738 = _rtmp3739.size || 0; + for (let _i740 = 0; _i740 < _size738; ++_i740) { + let elem741 = null; + elem741 = new data_ttypes.TObject(); + elem741.read(input); + val737.push(elem741); + } + input.readSetEnd(); + this.success[key736] = val737; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter742 in this.success) { + if (this.success.hasOwnProperty(kiter742)) { + let viter743 = this.success[kiter742]; + output.writeString(kiter742); + output.writeSetBegin(Thrift.Type.STRUCT, viter743.length); + for (let iter744 in viter743) { + if (viter743.hasOwnProperty(iter744)) { + iter744 = viter743[iter744]; + iter744.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3746 = input.readListBegin(); + const _size745 = _rtmp3746.size || 0; + for (let _i747 = 0; _i747 < _size745; ++_i747) { + let elem748 = null; + elem748 = input.readString(); + this.keys.push(elem748); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter749 in this.keys) { + if (this.keys.hasOwnProperty(iter749)) { + iter749 = this.keys[iter749]; + output.writeString(iter749); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3751 = input.readMapBegin(); + const _size750 = _rtmp3751.size || 0; + for (let _i752 = 0; _i752 < _size750; ++_i752) { + let key753 = null; + let val754 = null; + key753 = input.readString(); + val754 = []; + const _rtmp3756 = input.readSetBegin(); + const _size755 = _rtmp3756.size || 0; + for (let _i757 = 0; _i757 < _size755; ++_i757) { + let elem758 = null; + elem758 = new data_ttypes.TObject(); + elem758.read(input); + val754.push(elem758); + } + input.readSetEnd(); + this.success[key753] = val754; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter759 in this.success) { + if (this.success.hasOwnProperty(kiter759)) { + let viter760 = this.success[kiter759]; + output.writeString(kiter759); + output.writeSetBegin(Thrift.Type.STRUCT, viter760.length); + for (let iter761 in viter760) { + if (viter760.hasOwnProperty(iter761)) { + iter761 = viter760[iter761]; + iter761.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3763 = input.readListBegin(); + const _size762 = _rtmp3763.size || 0; + for (let _i764 = 0; _i764 < _size762; ++_i764) { + let elem765 = null; + elem765 = input.readString(); + this.keys.push(elem765); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter766 in this.keys) { + if (this.keys.hasOwnProperty(iter766)) { + iter766 = this.keys[iter766]; + output.writeString(iter766); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3768 = input.readMapBegin(); + const _size767 = _rtmp3768.size || 0; + for (let _i769 = 0; _i769 < _size767; ++_i769) { + let key770 = null; + let val771 = null; + key770 = input.readString(); + val771 = []; + const _rtmp3773 = input.readSetBegin(); + const _size772 = _rtmp3773.size || 0; + for (let _i774 = 0; _i774 < _size772; ++_i774) { + let elem775 = null; + elem775 = new data_ttypes.TObject(); + elem775.read(input); + val771.push(elem775); + } + input.readSetEnd(); + this.success[key770] = val771; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter776 in this.success) { + if (this.success.hasOwnProperty(kiter776)) { + let viter777 = this.success[kiter776]; + output.writeString(kiter776); + output.writeSetBegin(Thrift.Type.STRUCT, viter777.length); + for (let iter778 in viter777) { + if (viter777.hasOwnProperty(iter778)) { + iter778 = viter777[iter778]; + iter778.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3780 = input.readListBegin(); + const _size779 = _rtmp3780.size || 0; + for (let _i781 = 0; _i781 < _size779; ++_i781) { + let elem782 = null; + elem782 = input.readString(); + this.keys.push(elem782); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3784 = input.readListBegin(); + const _size783 = _rtmp3784.size || 0; + for (let _i785 = 0; _i785 < _size783; ++_i785) { + let elem786 = null; + elem786 = input.readI64(); + this.records.push(elem786); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter787 in this.keys) { + if (this.keys.hasOwnProperty(iter787)) { + iter787 = this.keys[iter787]; + output.writeString(iter787); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter788 in this.records) { + if (this.records.hasOwnProperty(iter788)) { + iter788 = this.records[iter788]; + output.writeI64(iter788); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3790 = input.readMapBegin(); + const _size789 = _rtmp3790.size || 0; + for (let _i791 = 0; _i791 < _size789; ++_i791) { + let key792 = null; + let val793 = null; + key792 = input.readI64(); + val793 = {}; + const _rtmp3795 = input.readMapBegin(); + const _size794 = _rtmp3795.size || 0; + for (let _i796 = 0; _i796 < _size794; ++_i796) { + let key797 = null; + let val798 = null; + key797 = input.readString(); + val798 = []; + const _rtmp3800 = input.readSetBegin(); + const _size799 = _rtmp3800.size || 0; + for (let _i801 = 0; _i801 < _size799; ++_i801) { + let elem802 = null; + elem802 = new data_ttypes.TObject(); + elem802.read(input); + val798.push(elem802); + } + input.readSetEnd(); + val793[key797] = val798; + } + input.readMapEnd(); + this.success[key792] = val793; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter803 in this.success) { + if (this.success.hasOwnProperty(kiter803)) { + let viter804 = this.success[kiter803]; + output.writeI64(kiter803); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter804)); + for (let kiter805 in viter804) { + if (viter804.hasOwnProperty(kiter805)) { + let viter806 = viter804[kiter805]; + output.writeString(kiter805); + output.writeSetBegin(Thrift.Type.STRUCT, viter806.length); + for (let iter807 in viter806) { + if (viter806.hasOwnProperty(iter807)) { + iter807 = viter806[iter807]; + iter807.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3809 = input.readListBegin(); + const _size808 = _rtmp3809.size || 0; + for (let _i810 = 0; _i810 < _size808; ++_i810) { + let elem811 = null; + elem811 = input.readI64(); + this.records.push(elem811); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter812 in this.records) { + if (this.records.hasOwnProperty(iter812)) { + iter812 = this.records[iter812]; + output.writeI64(iter812); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3814 = input.readMapBegin(); + const _size813 = _rtmp3814.size || 0; + for (let _i815 = 0; _i815 < _size813; ++_i815) { + let key816 = null; + let val817 = null; + key816 = input.readI64(); + val817 = []; + const _rtmp3819 = input.readSetBegin(); + const _size818 = _rtmp3819.size || 0; + for (let _i820 = 0; _i820 < _size818; ++_i820) { + let elem821 = null; + elem821 = new data_ttypes.TObject(); + elem821.read(input); + val817.push(elem821); + } + input.readSetEnd(); + this.success[key816] = val817; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter822 in this.success) { + if (this.success.hasOwnProperty(kiter822)) { + let viter823 = this.success[kiter822]; + output.writeI64(kiter822); + output.writeSetBegin(Thrift.Type.STRUCT, viter823.length); + for (let iter824 in viter823) { + if (viter823.hasOwnProperty(iter824)) { + iter824 = viter823[iter824]; + iter824.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3826 = input.readListBegin(); + const _size825 = _rtmp3826.size || 0; + for (let _i827 = 0; _i827 < _size825; ++_i827) { + let elem828 = null; + elem828 = input.readI64(); + this.records.push(elem828); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter829 in this.records) { + if (this.records.hasOwnProperty(iter829)) { + iter829 = this.records[iter829]; + output.writeI64(iter829); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3831 = input.readMapBegin(); + const _size830 = _rtmp3831.size || 0; + for (let _i832 = 0; _i832 < _size830; ++_i832) { + let key833 = null; + let val834 = null; + key833 = input.readI64(); + val834 = []; + const _rtmp3836 = input.readSetBegin(); + const _size835 = _rtmp3836.size || 0; + for (let _i837 = 0; _i837 < _size835; ++_i837) { + let elem838 = null; + elem838 = new data_ttypes.TObject(); + elem838.read(input); + val834.push(elem838); + } + input.readSetEnd(); + this.success[key833] = val834; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter839 in this.success) { + if (this.success.hasOwnProperty(kiter839)) { + let viter840 = this.success[kiter839]; + output.writeI64(kiter839); + output.writeSetBegin(Thrift.Type.STRUCT, viter840.length); + for (let iter841 in viter840) { + if (viter840.hasOwnProperty(iter841)) { + iter841 = viter840[iter841]; + iter841.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3843 = input.readListBegin(); + const _size842 = _rtmp3843.size || 0; + for (let _i844 = 0; _i844 < _size842; ++_i844) { + let elem845 = null; + elem845 = input.readI64(); + this.records.push(elem845); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter846 in this.records) { + if (this.records.hasOwnProperty(iter846)) { + iter846 = this.records[iter846]; + output.writeI64(iter846); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3848 = input.readMapBegin(); + const _size847 = _rtmp3848.size || 0; + for (let _i849 = 0; _i849 < _size847; ++_i849) { + let key850 = null; + let val851 = null; + key850 = input.readI64(); + val851 = []; + const _rtmp3853 = input.readSetBegin(); + const _size852 = _rtmp3853.size || 0; + for (let _i854 = 0; _i854 < _size852; ++_i854) { + let elem855 = null; + elem855 = new data_ttypes.TObject(); + elem855.read(input); + val851.push(elem855); + } + input.readSetEnd(); + this.success[key850] = val851; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter856 in this.success) { + if (this.success.hasOwnProperty(kiter856)) { + let viter857 = this.success[kiter856]; + output.writeI64(kiter856); + output.writeSetBegin(Thrift.Type.STRUCT, viter857.length); + for (let iter858 in viter857) { + if (viter857.hasOwnProperty(iter858)) { + iter858 = viter857[iter858]; + iter858.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3860 = input.readListBegin(); + const _size859 = _rtmp3860.size || 0; + for (let _i861 = 0; _i861 < _size859; ++_i861) { + let elem862 = null; + elem862 = input.readString(); + this.keys.push(elem862); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3864 = input.readListBegin(); + const _size863 = _rtmp3864.size || 0; + for (let _i865 = 0; _i865 < _size863; ++_i865) { + let elem866 = null; + elem866 = input.readI64(); + this.records.push(elem866); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter867 in this.keys) { + if (this.keys.hasOwnProperty(iter867)) { + iter867 = this.keys[iter867]; + output.writeString(iter867); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter868 in this.records) { + if (this.records.hasOwnProperty(iter868)) { + iter868 = this.records[iter868]; + output.writeI64(iter868); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3870 = input.readMapBegin(); + const _size869 = _rtmp3870.size || 0; + for (let _i871 = 0; _i871 < _size869; ++_i871) { + let key872 = null; + let val873 = null; + key872 = input.readI64(); + val873 = {}; + const _rtmp3875 = input.readMapBegin(); + const _size874 = _rtmp3875.size || 0; + for (let _i876 = 0; _i876 < _size874; ++_i876) { + let key877 = null; + let val878 = null; + key877 = input.readString(); + val878 = []; + const _rtmp3880 = input.readSetBegin(); + const _size879 = _rtmp3880.size || 0; + for (let _i881 = 0; _i881 < _size879; ++_i881) { + let elem882 = null; + elem882 = new data_ttypes.TObject(); + elem882.read(input); + val878.push(elem882); + } + input.readSetEnd(); + val873[key877] = val878; + } + input.readMapEnd(); + this.success[key872] = val873; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter883 in this.success) { + if (this.success.hasOwnProperty(kiter883)) { + let viter884 = this.success[kiter883]; + output.writeI64(kiter883); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter884)); + for (let kiter885 in viter884) { + if (viter884.hasOwnProperty(kiter885)) { + let viter886 = viter884[kiter885]; + output.writeString(kiter885); + output.writeSetBegin(Thrift.Type.STRUCT, viter886.length); + for (let iter887 in viter886) { + if (viter886.hasOwnProperty(iter887)) { + iter887 = viter886[iter887]; + iter887.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp3889 = input.readListBegin(); + const _size888 = _rtmp3889.size || 0; + for (let _i890 = 0; _i890 < _size888; ++_i890) { + let elem891 = null; + elem891 = input.readString(); + this.keys.push(elem891); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp3893 = input.readListBegin(); + const _size892 = _rtmp3893.size || 0; + for (let _i894 = 0; _i894 < _size892; ++_i894) { + let elem895 = null; + elem895 = input.readI64(); + this.records.push(elem895); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter896 in this.keys) { + if (this.keys.hasOwnProperty(iter896)) { + iter896 = this.keys[iter896]; + output.writeString(iter896); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter897 in this.records) { + if (this.records.hasOwnProperty(iter897)) { + iter897 = this.records[iter897]; + output.writeI64(iter897); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3899 = input.readMapBegin(); + const _size898 = _rtmp3899.size || 0; + for (let _i900 = 0; _i900 < _size898; ++_i900) { + let key901 = null; + let val902 = null; + key901 = input.readI64(); + val902 = {}; + const _rtmp3904 = input.readMapBegin(); + const _size903 = _rtmp3904.size || 0; + for (let _i905 = 0; _i905 < _size903; ++_i905) { + let key906 = null; + let val907 = null; + key906 = input.readString(); + val907 = []; + const _rtmp3909 = input.readSetBegin(); + const _size908 = _rtmp3909.size || 0; + for (let _i910 = 0; _i910 < _size908; ++_i910) { + let elem911 = null; + elem911 = new data_ttypes.TObject(); + elem911.read(input); + val907.push(elem911); + } + input.readSetEnd(); + val902[key906] = val907; + } + input.readMapEnd(); + this.success[key901] = val902; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter912 in this.success) { + if (this.success.hasOwnProperty(kiter912)) { + let viter913 = this.success[kiter912]; + output.writeI64(kiter912); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter913)); + for (let kiter914 in viter913) { + if (viter913.hasOwnProperty(kiter914)) { + let viter915 = viter913[kiter914]; + output.writeString(kiter914); + output.writeSetBegin(Thrift.Type.STRUCT, viter915.length); + for (let iter916 in viter915) { + if (viter915.hasOwnProperty(iter916)) { + iter916 = viter915[iter916]; + iter916.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCriteria_args = class { + constructor(args) { + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteria_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3918 = input.readMapBegin(); + const _size917 = _rtmp3918.size || 0; + for (let _i919 = 0; _i919 < _size917; ++_i919) { + let key920 = null; + let val921 = null; + key920 = input.readI64(); + val921 = {}; + const _rtmp3923 = input.readMapBegin(); + const _size922 = _rtmp3923.size || 0; + for (let _i924 = 0; _i924 < _size922; ++_i924) { + let key925 = null; + let val926 = null; + key925 = input.readString(); + val926 = []; + const _rtmp3928 = input.readSetBegin(); + const _size927 = _rtmp3928.size || 0; + for (let _i929 = 0; _i929 < _size927; ++_i929) { + let elem930 = null; + elem930 = new data_ttypes.TObject(); + elem930.read(input); + val926.push(elem930); + } + input.readSetEnd(); + val921[key925] = val926; + } + input.readMapEnd(); + this.success[key920] = val921; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter931 in this.success) { + if (this.success.hasOwnProperty(kiter931)) { + let viter932 = this.success[kiter931]; + output.writeI64(kiter931); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter932)); + for (let kiter933 in viter932) { + if (viter932.hasOwnProperty(kiter933)) { + let viter934 = viter932[kiter933]; + output.writeString(kiter933); + output.writeSetBegin(Thrift.Type.STRUCT, viter934.length); + for (let iter935 in viter934) { + if (viter934.hasOwnProperty(iter935)) { + iter935 = viter934[iter935]; + iter935.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCcl_args = class { + constructor(args) { + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCcl_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3937 = input.readMapBegin(); + const _size936 = _rtmp3937.size || 0; + for (let _i938 = 0; _i938 < _size936; ++_i938) { + let key939 = null; + let val940 = null; + key939 = input.readI64(); + val940 = {}; + const _rtmp3942 = input.readMapBegin(); + const _size941 = _rtmp3942.size || 0; + for (let _i943 = 0; _i943 < _size941; ++_i943) { + let key944 = null; + let val945 = null; + key944 = input.readString(); + val945 = []; + const _rtmp3947 = input.readSetBegin(); + const _size946 = _rtmp3947.size || 0; + for (let _i948 = 0; _i948 < _size946; ++_i948) { + let elem949 = null; + elem949 = new data_ttypes.TObject(); + elem949.read(input); + val945.push(elem949); + } + input.readSetEnd(); + val940[key944] = val945; + } + input.readMapEnd(); + this.success[key939] = val940; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter950 in this.success) { + if (this.success.hasOwnProperty(kiter950)) { + let viter951 = this.success[kiter950]; + output.writeI64(kiter950); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter951)); + for (let kiter952 in viter951) { + if (viter951.hasOwnProperty(kiter952)) { + let viter953 = viter951[kiter952]; + output.writeString(kiter952); + output.writeSetBegin(Thrift.Type.STRUCT, viter953.length); + for (let iter954 in viter953) { + if (viter953.hasOwnProperty(iter954)) { + iter954 = viter953[iter954]; + iter954.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCriteriaTime_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteriaTime_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3956 = input.readMapBegin(); + const _size955 = _rtmp3956.size || 0; + for (let _i957 = 0; _i957 < _size955; ++_i957) { + let key958 = null; + let val959 = null; + key958 = input.readI64(); + val959 = {}; + const _rtmp3961 = input.readMapBegin(); + const _size960 = _rtmp3961.size || 0; + for (let _i962 = 0; _i962 < _size960; ++_i962) { + let key963 = null; + let val964 = null; + key963 = input.readString(); + val964 = []; + const _rtmp3966 = input.readSetBegin(); + const _size965 = _rtmp3966.size || 0; + for (let _i967 = 0; _i967 < _size965; ++_i967) { + let elem968 = null; + elem968 = new data_ttypes.TObject(); + elem968.read(input); + val964.push(elem968); + } + input.readSetEnd(); + val959[key963] = val964; + } + input.readMapEnd(); + this.success[key958] = val959; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter969 in this.success) { + if (this.success.hasOwnProperty(kiter969)) { + let viter970 = this.success[kiter969]; + output.writeI64(kiter969); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter970)); + for (let kiter971 in viter970) { + if (viter970.hasOwnProperty(kiter971)) { + let viter972 = viter970[kiter971]; + output.writeString(kiter971); + output.writeSetBegin(Thrift.Type.STRUCT, viter972.length); + for (let iter973 in viter972) { + if (viter972.hasOwnProperty(iter973)) { + iter973 = viter972[iter973]; + iter973.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCriteriaTimestr_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteriaTimestr_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3975 = input.readMapBegin(); + const _size974 = _rtmp3975.size || 0; + for (let _i976 = 0; _i976 < _size974; ++_i976) { + let key977 = null; + let val978 = null; + key977 = input.readI64(); + val978 = {}; + const _rtmp3980 = input.readMapBegin(); + const _size979 = _rtmp3980.size || 0; + for (let _i981 = 0; _i981 < _size979; ++_i981) { + let key982 = null; + let val983 = null; + key982 = input.readString(); + val983 = []; + const _rtmp3985 = input.readSetBegin(); + const _size984 = _rtmp3985.size || 0; + for (let _i986 = 0; _i986 < _size984; ++_i986) { + let elem987 = null; + elem987 = new data_ttypes.TObject(); + elem987.read(input); + val983.push(elem987); + } + input.readSetEnd(); + val978[key982] = val983; + } + input.readMapEnd(); + this.success[key977] = val978; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter988 in this.success) { + if (this.success.hasOwnProperty(kiter988)) { + let viter989 = this.success[kiter988]; + output.writeI64(kiter988); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter989)); + for (let kiter990 in viter989) { + if (viter989.hasOwnProperty(kiter990)) { + let viter991 = viter989[kiter990]; + output.writeString(kiter990); + output.writeSetBegin(Thrift.Type.STRUCT, viter991.length); + for (let iter992 in viter991) { + if (viter991.hasOwnProperty(iter992)) { + iter992 = viter991[iter992]; + iter992.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCclTime_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCclTime_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp3994 = input.readMapBegin(); + const _size993 = _rtmp3994.size || 0; + for (let _i995 = 0; _i995 < _size993; ++_i995) { + let key996 = null; + let val997 = null; + key996 = input.readI64(); + val997 = {}; + const _rtmp3999 = input.readMapBegin(); + const _size998 = _rtmp3999.size || 0; + for (let _i1000 = 0; _i1000 < _size998; ++_i1000) { + let key1001 = null; + let val1002 = null; + key1001 = input.readString(); + val1002 = []; + const _rtmp31004 = input.readSetBegin(); + const _size1003 = _rtmp31004.size || 0; + for (let _i1005 = 0; _i1005 < _size1003; ++_i1005) { + let elem1006 = null; + elem1006 = new data_ttypes.TObject(); + elem1006.read(input); + val1002.push(elem1006); + } + input.readSetEnd(); + val997[key1001] = val1002; + } + input.readMapEnd(); + this.success[key996] = val997; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1007 in this.success) { + if (this.success.hasOwnProperty(kiter1007)) { + let viter1008 = this.success[kiter1007]; + output.writeI64(kiter1007); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1008)); + for (let kiter1009 in viter1008) { + if (viter1008.hasOwnProperty(kiter1009)) { + let viter1010 = viter1008[kiter1009]; + output.writeString(kiter1009); + output.writeSetBegin(Thrift.Type.STRUCT, viter1010.length); + for (let iter1011 in viter1010) { + if (viter1010.hasOwnProperty(iter1011)) { + iter1011 = viter1010[iter1011]; + iter1011.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCclTimestr_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCclTimestr_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31013 = input.readMapBegin(); + const _size1012 = _rtmp31013.size || 0; + for (let _i1014 = 0; _i1014 < _size1012; ++_i1014) { + let key1015 = null; + let val1016 = null; + key1015 = input.readI64(); + val1016 = {}; + const _rtmp31018 = input.readMapBegin(); + const _size1017 = _rtmp31018.size || 0; + for (let _i1019 = 0; _i1019 < _size1017; ++_i1019) { + let key1020 = null; + let val1021 = null; + key1020 = input.readString(); + val1021 = []; + const _rtmp31023 = input.readSetBegin(); + const _size1022 = _rtmp31023.size || 0; + for (let _i1024 = 0; _i1024 < _size1022; ++_i1024) { + let elem1025 = null; + elem1025 = new data_ttypes.TObject(); + elem1025.read(input); + val1021.push(elem1025); + } + input.readSetEnd(); + val1016[key1020] = val1021; + } + input.readMapEnd(); + this.success[key1015] = val1016; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1026 in this.success) { + if (this.success.hasOwnProperty(kiter1026)) { + let viter1027 = this.success[kiter1026]; + output.writeI64(kiter1026); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1027)); + for (let kiter1028 in viter1027) { + if (viter1027.hasOwnProperty(kiter1028)) { + let viter1029 = viter1027[kiter1028]; + output.writeString(kiter1028); + output.writeSetBegin(Thrift.Type.STRUCT, viter1029.length); + for (let iter1030 in viter1029) { + if (viter1029.hasOwnProperty(iter1030)) { + iter1030 = viter1029[iter1030]; + iter1030.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31032 = input.readMapBegin(); + const _size1031 = _rtmp31032.size || 0; + for (let _i1033 = 0; _i1033 < _size1031; ++_i1033) { + let key1034 = null; + let val1035 = null; + key1034 = input.readI64(); + val1035 = []; + const _rtmp31037 = input.readSetBegin(); + const _size1036 = _rtmp31037.size || 0; + for (let _i1038 = 0; _i1038 < _size1036; ++_i1038) { + let elem1039 = null; + elem1039 = new data_ttypes.TObject(); + elem1039.read(input); + val1035.push(elem1039); + } + input.readSetEnd(); + this.success[key1034] = val1035; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1040 in this.success) { + if (this.success.hasOwnProperty(kiter1040)) { + let viter1041 = this.success[kiter1040]; + output.writeI64(kiter1040); + output.writeSetBegin(Thrift.Type.STRUCT, viter1041.length); + for (let iter1042 in viter1041) { + if (viter1041.hasOwnProperty(iter1042)) { + iter1042 = viter1041[iter1042]; + iter1042.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31044 = input.readMapBegin(); + const _size1043 = _rtmp31044.size || 0; + for (let _i1045 = 0; _i1045 < _size1043; ++_i1045) { + let key1046 = null; + let val1047 = null; + key1046 = input.readI64(); + val1047 = []; + const _rtmp31049 = input.readSetBegin(); + const _size1048 = _rtmp31049.size || 0; + for (let _i1050 = 0; _i1050 < _size1048; ++_i1050) { + let elem1051 = null; + elem1051 = new data_ttypes.TObject(); + elem1051.read(input); + val1047.push(elem1051); + } + input.readSetEnd(); + this.success[key1046] = val1047; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1052 in this.success) { + if (this.success.hasOwnProperty(kiter1052)) { + let viter1053 = this.success[kiter1052]; + output.writeI64(kiter1052); + output.writeSetBegin(Thrift.Type.STRUCT, viter1053.length); + for (let iter1054 in viter1053) { + if (viter1053.hasOwnProperty(iter1054)) { + iter1054 = viter1053[iter1054]; + iter1054.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31056 = input.readMapBegin(); + const _size1055 = _rtmp31056.size || 0; + for (let _i1057 = 0; _i1057 < _size1055; ++_i1057) { + let key1058 = null; + let val1059 = null; + key1058 = input.readI64(); + val1059 = []; + const _rtmp31061 = input.readSetBegin(); + const _size1060 = _rtmp31061.size || 0; + for (let _i1062 = 0; _i1062 < _size1060; ++_i1062) { + let elem1063 = null; + elem1063 = new data_ttypes.TObject(); + elem1063.read(input); + val1059.push(elem1063); + } + input.readSetEnd(); + this.success[key1058] = val1059; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1064 in this.success) { + if (this.success.hasOwnProperty(kiter1064)) { + let viter1065 = this.success[kiter1064]; + output.writeI64(kiter1064); + output.writeSetBegin(Thrift.Type.STRUCT, viter1065.length); + for (let iter1066 in viter1065) { + if (viter1065.hasOwnProperty(iter1066)) { + iter1066 = viter1065[iter1066]; + iter1066.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31068 = input.readMapBegin(); + const _size1067 = _rtmp31068.size || 0; + for (let _i1069 = 0; _i1069 < _size1067; ++_i1069) { + let key1070 = null; + let val1071 = null; + key1070 = input.readI64(); + val1071 = []; + const _rtmp31073 = input.readSetBegin(); + const _size1072 = _rtmp31073.size || 0; + for (let _i1074 = 0; _i1074 < _size1072; ++_i1074) { + let elem1075 = null; + elem1075 = new data_ttypes.TObject(); + elem1075.read(input); + val1071.push(elem1075); + } + input.readSetEnd(); + this.success[key1070] = val1071; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1076 in this.success) { + if (this.success.hasOwnProperty(kiter1076)) { + let viter1077 = this.success[kiter1076]; + output.writeI64(kiter1076); + output.writeSetBegin(Thrift.Type.STRUCT, viter1077.length); + for (let iter1078 in viter1077) { + if (viter1077.hasOwnProperty(iter1078)) { + iter1078 = viter1077[iter1078]; + iter1078.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31080 = input.readMapBegin(); + const _size1079 = _rtmp31080.size || 0; + for (let _i1081 = 0; _i1081 < _size1079; ++_i1081) { + let key1082 = null; + let val1083 = null; + key1082 = input.readI64(); + val1083 = []; + const _rtmp31085 = input.readSetBegin(); + const _size1084 = _rtmp31085.size || 0; + for (let _i1086 = 0; _i1086 < _size1084; ++_i1086) { + let elem1087 = null; + elem1087 = new data_ttypes.TObject(); + elem1087.read(input); + val1083.push(elem1087); + } + input.readSetEnd(); + this.success[key1082] = val1083; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1088 in this.success) { + if (this.success.hasOwnProperty(kiter1088)) { + let viter1089 = this.success[kiter1088]; + output.writeI64(kiter1088); + output.writeSetBegin(Thrift.Type.STRUCT, viter1089.length); + for (let iter1090 in viter1089) { + if (viter1089.hasOwnProperty(iter1090)) { + iter1090 = viter1089[iter1090]; + iter1090.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31092 = input.readMapBegin(); + const _size1091 = _rtmp31092.size || 0; + for (let _i1093 = 0; _i1093 < _size1091; ++_i1093) { + let key1094 = null; + let val1095 = null; + key1094 = input.readI64(); + val1095 = []; + const _rtmp31097 = input.readSetBegin(); + const _size1096 = _rtmp31097.size || 0; + for (let _i1098 = 0; _i1098 < _size1096; ++_i1098) { + let elem1099 = null; + elem1099 = new data_ttypes.TObject(); + elem1099.read(input); + val1095.push(elem1099); + } + input.readSetEnd(); + this.success[key1094] = val1095; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1100 in this.success) { + if (this.success.hasOwnProperty(kiter1100)) { + let viter1101 = this.success[kiter1100]; + output.writeI64(kiter1100); + output.writeSetBegin(Thrift.Type.STRUCT, viter1101.length); + for (let iter1102 in viter1101) { + if (viter1101.hasOwnProperty(iter1102)) { + iter1102 = viter1101[iter1102]; + iter1102.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCriteria_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31104 = input.readListBegin(); + const _size1103 = _rtmp31104.size || 0; + for (let _i1105 = 0; _i1105 < _size1103; ++_i1105) { + let elem1106 = null; + elem1106 = input.readString(); + this.keys.push(elem1106); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteria_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1107 in this.keys) { + if (this.keys.hasOwnProperty(iter1107)) { + iter1107 = this.keys[iter1107]; + output.writeString(iter1107); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31109 = input.readMapBegin(); + const _size1108 = _rtmp31109.size || 0; + for (let _i1110 = 0; _i1110 < _size1108; ++_i1110) { + let key1111 = null; + let val1112 = null; + key1111 = input.readI64(); + val1112 = {}; + const _rtmp31114 = input.readMapBegin(); + const _size1113 = _rtmp31114.size || 0; + for (let _i1115 = 0; _i1115 < _size1113; ++_i1115) { + let key1116 = null; + let val1117 = null; + key1116 = input.readString(); + val1117 = []; + const _rtmp31119 = input.readSetBegin(); + const _size1118 = _rtmp31119.size || 0; + for (let _i1120 = 0; _i1120 < _size1118; ++_i1120) { + let elem1121 = null; + elem1121 = new data_ttypes.TObject(); + elem1121.read(input); + val1117.push(elem1121); + } + input.readSetEnd(); + val1112[key1116] = val1117; + } + input.readMapEnd(); + this.success[key1111] = val1112; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1122 in this.success) { + if (this.success.hasOwnProperty(kiter1122)) { + let viter1123 = this.success[kiter1122]; + output.writeI64(kiter1122); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1123)); + for (let kiter1124 in viter1123) { + if (viter1123.hasOwnProperty(kiter1124)) { + let viter1125 = viter1123[kiter1124]; + output.writeString(kiter1124); + output.writeSetBegin(Thrift.Type.STRUCT, viter1125.length); + for (let iter1126 in viter1125) { + if (viter1125.hasOwnProperty(iter1126)) { + iter1126 = viter1125[iter1126]; + iter1126.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCcl_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31128 = input.readListBegin(); + const _size1127 = _rtmp31128.size || 0; + for (let _i1129 = 0; _i1129 < _size1127; ++_i1129) { + let elem1130 = null; + elem1130 = input.readString(); + this.keys.push(elem1130); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCcl_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1131 in this.keys) { + if (this.keys.hasOwnProperty(iter1131)) { + iter1131 = this.keys[iter1131]; + output.writeString(iter1131); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31133 = input.readMapBegin(); + const _size1132 = _rtmp31133.size || 0; + for (let _i1134 = 0; _i1134 < _size1132; ++_i1134) { + let key1135 = null; + let val1136 = null; + key1135 = input.readI64(); + val1136 = {}; + const _rtmp31138 = input.readMapBegin(); + const _size1137 = _rtmp31138.size || 0; + for (let _i1139 = 0; _i1139 < _size1137; ++_i1139) { + let key1140 = null; + let val1141 = null; + key1140 = input.readString(); + val1141 = []; + const _rtmp31143 = input.readSetBegin(); + const _size1142 = _rtmp31143.size || 0; + for (let _i1144 = 0; _i1144 < _size1142; ++_i1144) { + let elem1145 = null; + elem1145 = new data_ttypes.TObject(); + elem1145.read(input); + val1141.push(elem1145); + } + input.readSetEnd(); + val1136[key1140] = val1141; + } + input.readMapEnd(); + this.success[key1135] = val1136; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1146 in this.success) { + if (this.success.hasOwnProperty(kiter1146)) { + let viter1147 = this.success[kiter1146]; + output.writeI64(kiter1146); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1147)); + for (let kiter1148 in viter1147) { + if (viter1147.hasOwnProperty(kiter1148)) { + let viter1149 = viter1147[kiter1148]; + output.writeString(kiter1148); + output.writeSetBegin(Thrift.Type.STRUCT, viter1149.length); + for (let iter1150 in viter1149) { + if (viter1149.hasOwnProperty(iter1150)) { + iter1150 = viter1149[iter1150]; + iter1150.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCriteriaTime_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31152 = input.readListBegin(); + const _size1151 = _rtmp31152.size || 0; + for (let _i1153 = 0; _i1153 < _size1151; ++_i1153) { + let elem1154 = null; + elem1154 = input.readString(); + this.keys.push(elem1154); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteriaTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1155 in this.keys) { + if (this.keys.hasOwnProperty(iter1155)) { + iter1155 = this.keys[iter1155]; + output.writeString(iter1155); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31157 = input.readMapBegin(); + const _size1156 = _rtmp31157.size || 0; + for (let _i1158 = 0; _i1158 < _size1156; ++_i1158) { + let key1159 = null; + let val1160 = null; + key1159 = input.readI64(); + val1160 = {}; + const _rtmp31162 = input.readMapBegin(); + const _size1161 = _rtmp31162.size || 0; + for (let _i1163 = 0; _i1163 < _size1161; ++_i1163) { + let key1164 = null; + let val1165 = null; + key1164 = input.readString(); + val1165 = []; + const _rtmp31167 = input.readSetBegin(); + const _size1166 = _rtmp31167.size || 0; + for (let _i1168 = 0; _i1168 < _size1166; ++_i1168) { + let elem1169 = null; + elem1169 = new data_ttypes.TObject(); + elem1169.read(input); + val1165.push(elem1169); + } + input.readSetEnd(); + val1160[key1164] = val1165; + } + input.readMapEnd(); + this.success[key1159] = val1160; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1170 in this.success) { + if (this.success.hasOwnProperty(kiter1170)) { + let viter1171 = this.success[kiter1170]; + output.writeI64(kiter1170); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1171)); + for (let kiter1172 in viter1171) { + if (viter1171.hasOwnProperty(kiter1172)) { + let viter1173 = viter1171[kiter1172]; + output.writeString(kiter1172); + output.writeSetBegin(Thrift.Type.STRUCT, viter1173.length); + for (let iter1174 in viter1173) { + if (viter1173.hasOwnProperty(iter1174)) { + iter1174 = viter1173[iter1174]; + iter1174.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCriteriaTimestr_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31176 = input.readListBegin(); + const _size1175 = _rtmp31176.size || 0; + for (let _i1177 = 0; _i1177 < _size1175; ++_i1177) { + let elem1178 = null; + elem1178 = input.readString(); + this.keys.push(elem1178); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteriaTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1179 in this.keys) { + if (this.keys.hasOwnProperty(iter1179)) { + iter1179 = this.keys[iter1179]; + output.writeString(iter1179); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31181 = input.readMapBegin(); + const _size1180 = _rtmp31181.size || 0; + for (let _i1182 = 0; _i1182 < _size1180; ++_i1182) { + let key1183 = null; + let val1184 = null; + key1183 = input.readI64(); + val1184 = {}; + const _rtmp31186 = input.readMapBegin(); + const _size1185 = _rtmp31186.size || 0; + for (let _i1187 = 0; _i1187 < _size1185; ++_i1187) { + let key1188 = null; + let val1189 = null; + key1188 = input.readString(); + val1189 = []; + const _rtmp31191 = input.readSetBegin(); + const _size1190 = _rtmp31191.size || 0; + for (let _i1192 = 0; _i1192 < _size1190; ++_i1192) { + let elem1193 = null; + elem1193 = new data_ttypes.TObject(); + elem1193.read(input); + val1189.push(elem1193); + } + input.readSetEnd(); + val1184[key1188] = val1189; + } + input.readMapEnd(); + this.success[key1183] = val1184; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1194 in this.success) { + if (this.success.hasOwnProperty(kiter1194)) { + let viter1195 = this.success[kiter1194]; + output.writeI64(kiter1194); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1195)); + for (let kiter1196 in viter1195) { + if (viter1195.hasOwnProperty(kiter1196)) { + let viter1197 = viter1195[kiter1196]; + output.writeString(kiter1196); + output.writeSetBegin(Thrift.Type.STRUCT, viter1197.length); + for (let iter1198 in viter1197) { + if (viter1197.hasOwnProperty(iter1198)) { + iter1198 = viter1197[iter1198]; + iter1198.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCclTime_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31200 = input.readListBegin(); + const _size1199 = _rtmp31200.size || 0; + for (let _i1201 = 0; _i1201 < _size1199; ++_i1201) { + let elem1202 = null; + elem1202 = input.readString(); + this.keys.push(elem1202); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCclTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1203 in this.keys) { + if (this.keys.hasOwnProperty(iter1203)) { + iter1203 = this.keys[iter1203]; + output.writeString(iter1203); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31205 = input.readMapBegin(); + const _size1204 = _rtmp31205.size || 0; + for (let _i1206 = 0; _i1206 < _size1204; ++_i1206) { + let key1207 = null; + let val1208 = null; + key1207 = input.readI64(); + val1208 = {}; + const _rtmp31210 = input.readMapBegin(); + const _size1209 = _rtmp31210.size || 0; + for (let _i1211 = 0; _i1211 < _size1209; ++_i1211) { + let key1212 = null; + let val1213 = null; + key1212 = input.readString(); + val1213 = []; + const _rtmp31215 = input.readSetBegin(); + const _size1214 = _rtmp31215.size || 0; + for (let _i1216 = 0; _i1216 < _size1214; ++_i1216) { + let elem1217 = null; + elem1217 = new data_ttypes.TObject(); + elem1217.read(input); + val1213.push(elem1217); + } + input.readSetEnd(); + val1208[key1212] = val1213; + } + input.readMapEnd(); + this.success[key1207] = val1208; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1218 in this.success) { + if (this.success.hasOwnProperty(kiter1218)) { + let viter1219 = this.success[kiter1218]; + output.writeI64(kiter1218); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1219)); + for (let kiter1220 in viter1219) { + if (viter1219.hasOwnProperty(kiter1220)) { + let viter1221 = viter1219[kiter1220]; + output.writeString(kiter1220); + output.writeSetBegin(Thrift.Type.STRUCT, viter1221.length); + for (let iter1222 in viter1221) { + if (viter1221.hasOwnProperty(iter1222)) { + iter1222 = viter1221[iter1222]; + iter1222.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCclTimestr_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31224 = input.readListBegin(); + const _size1223 = _rtmp31224.size || 0; + for (let _i1225 = 0; _i1225 < _size1223; ++_i1225) { + let elem1226 = null; + elem1226 = input.readString(); + this.keys.push(elem1226); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCclTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1227 in this.keys) { + if (this.keys.hasOwnProperty(iter1227)) { + iter1227 = this.keys[iter1227]; + output.writeString(iter1227); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_selectKeysCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31229 = input.readMapBegin(); + const _size1228 = _rtmp31229.size || 0; + for (let _i1230 = 0; _i1230 < _size1228; ++_i1230) { + let key1231 = null; + let val1232 = null; + key1231 = input.readI64(); + val1232 = {}; + const _rtmp31234 = input.readMapBegin(); + const _size1233 = _rtmp31234.size || 0; + for (let _i1235 = 0; _i1235 < _size1233; ++_i1235) { + let key1236 = null; + let val1237 = null; + key1236 = input.readString(); + val1237 = []; + const _rtmp31239 = input.readSetBegin(); + const _size1238 = _rtmp31239.size || 0; + for (let _i1240 = 0; _i1240 < _size1238; ++_i1240) { + let elem1241 = null; + elem1241 = new data_ttypes.TObject(); + elem1241.read(input); + val1237.push(elem1241); + } + input.readSetEnd(); + val1232[key1236] = val1237; + } + input.readMapEnd(); + this.success[key1231] = val1232; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_selectKeysCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1242 in this.success) { + if (this.success.hasOwnProperty(kiter1242)) { + let viter1243 = this.success[kiter1242]; + output.writeI64(kiter1242); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1243)); + for (let kiter1244 in viter1243) { + if (viter1243.hasOwnProperty(kiter1244)) { + let viter1245 = viter1243[kiter1244]; + output.writeString(kiter1244); + output.writeSetBegin(Thrift.Type.STRUCT, viter1245.length); + for (let iter1246 in viter1245) { + if (viter1245.hasOwnProperty(iter1246)) { + iter1246 = viter1245[iter1246]; + iter1246.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31248 = input.readListBegin(); + const _size1247 = _rtmp31248.size || 0; + for (let _i1249 = 0; _i1249 < _size1247; ++_i1249) { + let elem1250 = null; + elem1250 = input.readString(); + this.keys.push(elem1250); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1251 in this.keys) { + if (this.keys.hasOwnProperty(iter1251)) { + iter1251 = this.keys[iter1251]; + output.writeString(iter1251); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31253 = input.readMapBegin(); + const _size1252 = _rtmp31253.size || 0; + for (let _i1254 = 0; _i1254 < _size1252; ++_i1254) { + let key1255 = null; + let val1256 = null; + key1255 = input.readString(); + val1256 = new data_ttypes.TObject(); + val1256.read(input); + this.success[key1255] = val1256; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1257 in this.success) { + if (this.success.hasOwnProperty(kiter1257)) { + let viter1258 = this.success[kiter1257]; + output.writeString(kiter1257); + viter1258.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31260 = input.readListBegin(); + const _size1259 = _rtmp31260.size || 0; + for (let _i1261 = 0; _i1261 < _size1259; ++_i1261) { + let elem1262 = null; + elem1262 = input.readString(); + this.keys.push(elem1262); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1263 in this.keys) { + if (this.keys.hasOwnProperty(iter1263)) { + iter1263 = this.keys[iter1263]; + output.writeString(iter1263); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31265 = input.readMapBegin(); + const _size1264 = _rtmp31265.size || 0; + for (let _i1266 = 0; _i1266 < _size1264; ++_i1266) { + let key1267 = null; + let val1268 = null; + key1267 = input.readString(); + val1268 = new data_ttypes.TObject(); + val1268.read(input); + this.success[key1267] = val1268; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1269 in this.success) { + if (this.success.hasOwnProperty(kiter1269)) { + let viter1270 = this.success[kiter1269]; + output.writeString(kiter1269); + viter1270.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31272 = input.readListBegin(); + const _size1271 = _rtmp31272.size || 0; + for (let _i1273 = 0; _i1273 < _size1271; ++_i1273) { + let elem1274 = null; + elem1274 = input.readString(); + this.keys.push(elem1274); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1275 in this.keys) { + if (this.keys.hasOwnProperty(iter1275)) { + iter1275 = this.keys[iter1275]; + output.writeString(iter1275); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31277 = input.readMapBegin(); + const _size1276 = _rtmp31277.size || 0; + for (let _i1278 = 0; _i1278 < _size1276; ++_i1278) { + let key1279 = null; + let val1280 = null; + key1279 = input.readString(); + val1280 = new data_ttypes.TObject(); + val1280.read(input); + this.success[key1279] = val1280; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1281 in this.success) { + if (this.success.hasOwnProperty(kiter1281)) { + let viter1282 = this.success[kiter1281]; + output.writeString(kiter1281); + viter1282.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31284 = input.readListBegin(); + const _size1283 = _rtmp31284.size || 0; + for (let _i1285 = 0; _i1285 < _size1283; ++_i1285) { + let elem1286 = null; + elem1286 = input.readString(); + this.keys.push(elem1286); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31288 = input.readListBegin(); + const _size1287 = _rtmp31288.size || 0; + for (let _i1289 = 0; _i1289 < _size1287; ++_i1289) { + let elem1290 = null; + elem1290 = input.readI64(); + this.records.push(elem1290); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1291 in this.keys) { + if (this.keys.hasOwnProperty(iter1291)) { + iter1291 = this.keys[iter1291]; + output.writeString(iter1291); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1292 in this.records) { + if (this.records.hasOwnProperty(iter1292)) { + iter1292 = this.records[iter1292]; + output.writeI64(iter1292); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31294 = input.readMapBegin(); + const _size1293 = _rtmp31294.size || 0; + for (let _i1295 = 0; _i1295 < _size1293; ++_i1295) { + let key1296 = null; + let val1297 = null; + key1296 = input.readI64(); + val1297 = {}; + const _rtmp31299 = input.readMapBegin(); + const _size1298 = _rtmp31299.size || 0; + for (let _i1300 = 0; _i1300 < _size1298; ++_i1300) { + let key1301 = null; + let val1302 = null; + key1301 = input.readString(); + val1302 = new data_ttypes.TObject(); + val1302.read(input); + val1297[key1301] = val1302; + } + input.readMapEnd(); + this.success[key1296] = val1297; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1303 in this.success) { + if (this.success.hasOwnProperty(kiter1303)) { + let viter1304 = this.success[kiter1303]; + output.writeI64(kiter1303); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1304)); + for (let kiter1305 in viter1304) { + if (viter1304.hasOwnProperty(kiter1305)) { + let viter1306 = viter1304[kiter1305]; + output.writeString(kiter1305); + viter1306.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31308 = input.readListBegin(); + const _size1307 = _rtmp31308.size || 0; + for (let _i1309 = 0; _i1309 < _size1307; ++_i1309) { + let elem1310 = null; + elem1310 = input.readI64(); + this.records.push(elem1310); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1311 in this.records) { + if (this.records.hasOwnProperty(iter1311)) { + iter1311 = this.records[iter1311]; + output.writeI64(iter1311); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31313 = input.readMapBegin(); + const _size1312 = _rtmp31313.size || 0; + for (let _i1314 = 0; _i1314 < _size1312; ++_i1314) { + let key1315 = null; + let val1316 = null; + key1315 = input.readI64(); + val1316 = new data_ttypes.TObject(); + val1316.read(input); + this.success[key1315] = val1316; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1317 in this.success) { + if (this.success.hasOwnProperty(kiter1317)) { + let viter1318 = this.success[kiter1317]; + output.writeI64(kiter1317); + viter1318.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31320 = input.readListBegin(); + const _size1319 = _rtmp31320.size || 0; + for (let _i1321 = 0; _i1321 < _size1319; ++_i1321) { + let elem1322 = null; + elem1322 = input.readI64(); + this.records.push(elem1322); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1323 in this.records) { + if (this.records.hasOwnProperty(iter1323)) { + iter1323 = this.records[iter1323]; + output.writeI64(iter1323); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31325 = input.readMapBegin(); + const _size1324 = _rtmp31325.size || 0; + for (let _i1326 = 0; _i1326 < _size1324; ++_i1326) { + let key1327 = null; + let val1328 = null; + key1327 = input.readI64(); + val1328 = new data_ttypes.TObject(); + val1328.read(input); + this.success[key1327] = val1328; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1329 in this.success) { + if (this.success.hasOwnProperty(kiter1329)) { + let viter1330 = this.success[kiter1329]; + output.writeI64(kiter1329); + viter1330.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31332 = input.readListBegin(); + const _size1331 = _rtmp31332.size || 0; + for (let _i1333 = 0; _i1333 < _size1331; ++_i1333) { + let elem1334 = null; + elem1334 = input.readI64(); + this.records.push(elem1334); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1335 in this.records) { + if (this.records.hasOwnProperty(iter1335)) { + iter1335 = this.records[iter1335]; + output.writeI64(iter1335); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31337 = input.readMapBegin(); + const _size1336 = _rtmp31337.size || 0; + for (let _i1338 = 0; _i1338 < _size1336; ++_i1338) { + let key1339 = null; + let val1340 = null; + key1339 = input.readI64(); + val1340 = new data_ttypes.TObject(); + val1340.read(input); + this.success[key1339] = val1340; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1341 in this.success) { + if (this.success.hasOwnProperty(kiter1341)) { + let viter1342 = this.success[kiter1341]; + output.writeI64(kiter1341); + viter1342.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31344 = input.readListBegin(); + const _size1343 = _rtmp31344.size || 0; + for (let _i1345 = 0; _i1345 < _size1343; ++_i1345) { + let elem1346 = null; + elem1346 = input.readString(); + this.keys.push(elem1346); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31348 = input.readListBegin(); + const _size1347 = _rtmp31348.size || 0; + for (let _i1349 = 0; _i1349 < _size1347; ++_i1349) { + let elem1350 = null; + elem1350 = input.readI64(); + this.records.push(elem1350); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1351 in this.keys) { + if (this.keys.hasOwnProperty(iter1351)) { + iter1351 = this.keys[iter1351]; + output.writeString(iter1351); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1352 in this.records) { + if (this.records.hasOwnProperty(iter1352)) { + iter1352 = this.records[iter1352]; + output.writeI64(iter1352); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31354 = input.readMapBegin(); + const _size1353 = _rtmp31354.size || 0; + for (let _i1355 = 0; _i1355 < _size1353; ++_i1355) { + let key1356 = null; + let val1357 = null; + key1356 = input.readI64(); + val1357 = {}; + const _rtmp31359 = input.readMapBegin(); + const _size1358 = _rtmp31359.size || 0; + for (let _i1360 = 0; _i1360 < _size1358; ++_i1360) { + let key1361 = null; + let val1362 = null; + key1361 = input.readString(); + val1362 = new data_ttypes.TObject(); + val1362.read(input); + val1357[key1361] = val1362; + } + input.readMapEnd(); + this.success[key1356] = val1357; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1363 in this.success) { + if (this.success.hasOwnProperty(kiter1363)) { + let viter1364 = this.success[kiter1363]; + output.writeI64(kiter1363); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1364)); + for (let kiter1365 in viter1364) { + if (viter1364.hasOwnProperty(kiter1365)) { + let viter1366 = viter1364[kiter1365]; + output.writeString(kiter1365); + viter1366.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31368 = input.readListBegin(); + const _size1367 = _rtmp31368.size || 0; + for (let _i1369 = 0; _i1369 < _size1367; ++_i1369) { + let elem1370 = null; + elem1370 = input.readString(); + this.keys.push(elem1370); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31372 = input.readListBegin(); + const _size1371 = _rtmp31372.size || 0; + for (let _i1373 = 0; _i1373 < _size1371; ++_i1373) { + let elem1374 = null; + elem1374 = input.readI64(); + this.records.push(elem1374); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1375 in this.keys) { + if (this.keys.hasOwnProperty(iter1375)) { + iter1375 = this.keys[iter1375]; + output.writeString(iter1375); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1376 in this.records) { + if (this.records.hasOwnProperty(iter1376)) { + iter1376 = this.records[iter1376]; + output.writeI64(iter1376); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31378 = input.readMapBegin(); + const _size1377 = _rtmp31378.size || 0; + for (let _i1379 = 0; _i1379 < _size1377; ++_i1379) { + let key1380 = null; + let val1381 = null; + key1380 = input.readI64(); + val1381 = {}; + const _rtmp31383 = input.readMapBegin(); + const _size1382 = _rtmp31383.size || 0; + for (let _i1384 = 0; _i1384 < _size1382; ++_i1384) { + let key1385 = null; + let val1386 = null; + key1385 = input.readString(); + val1386 = new data_ttypes.TObject(); + val1386.read(input); + val1381[key1385] = val1386; + } + input.readMapEnd(); + this.success[key1380] = val1381; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1387 in this.success) { + if (this.success.hasOwnProperty(kiter1387)) { + let viter1388 = this.success[kiter1387]; + output.writeI64(kiter1387); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1388)); + for (let kiter1389 in viter1388) { + if (viter1388.hasOwnProperty(kiter1389)) { + let viter1390 = viter1388[kiter1389]; + output.writeString(kiter1389); + viter1390.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31392 = input.readMapBegin(); + const _size1391 = _rtmp31392.size || 0; + for (let _i1393 = 0; _i1393 < _size1391; ++_i1393) { + let key1394 = null; + let val1395 = null; + key1394 = input.readI64(); + val1395 = new data_ttypes.TObject(); + val1395.read(input); + this.success[key1394] = val1395; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1396 in this.success) { + if (this.success.hasOwnProperty(kiter1396)) { + let viter1397 = this.success[kiter1396]; + output.writeI64(kiter1396); + viter1397.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCriteria_args = class { + constructor(args) { + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteria_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31399 = input.readMapBegin(); + const _size1398 = _rtmp31399.size || 0; + for (let _i1400 = 0; _i1400 < _size1398; ++_i1400) { + let key1401 = null; + let val1402 = null; + key1401 = input.readI64(); + val1402 = {}; + const _rtmp31404 = input.readMapBegin(); + const _size1403 = _rtmp31404.size || 0; + for (let _i1405 = 0; _i1405 < _size1403; ++_i1405) { + let key1406 = null; + let val1407 = null; + key1406 = input.readString(); + val1407 = new data_ttypes.TObject(); + val1407.read(input); + val1402[key1406] = val1407; + } + input.readMapEnd(); + this.success[key1401] = val1402; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1408 in this.success) { + if (this.success.hasOwnProperty(kiter1408)) { + let viter1409 = this.success[kiter1408]; + output.writeI64(kiter1408); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1409)); + for (let kiter1410 in viter1409) { + if (viter1409.hasOwnProperty(kiter1410)) { + let viter1411 = viter1409[kiter1410]; + output.writeString(kiter1410); + viter1411.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCcl_args = class { + constructor(args) { + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCcl_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31413 = input.readMapBegin(); + const _size1412 = _rtmp31413.size || 0; + for (let _i1414 = 0; _i1414 < _size1412; ++_i1414) { + let key1415 = null; + let val1416 = null; + key1415 = input.readI64(); + val1416 = {}; + const _rtmp31418 = input.readMapBegin(); + const _size1417 = _rtmp31418.size || 0; + for (let _i1419 = 0; _i1419 < _size1417; ++_i1419) { + let key1420 = null; + let val1421 = null; + key1420 = input.readString(); + val1421 = new data_ttypes.TObject(); + val1421.read(input); + val1416[key1420] = val1421; + } + input.readMapEnd(); + this.success[key1415] = val1416; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1422 in this.success) { + if (this.success.hasOwnProperty(kiter1422)) { + let viter1423 = this.success[kiter1422]; + output.writeI64(kiter1422); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1423)); + for (let kiter1424 in viter1423) { + if (viter1423.hasOwnProperty(kiter1424)) { + let viter1425 = viter1423[kiter1424]; + output.writeString(kiter1424); + viter1425.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCriteriaTime_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteriaTime_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31427 = input.readMapBegin(); + const _size1426 = _rtmp31427.size || 0; + for (let _i1428 = 0; _i1428 < _size1426; ++_i1428) { + let key1429 = null; + let val1430 = null; + key1429 = input.readI64(); + val1430 = {}; + const _rtmp31432 = input.readMapBegin(); + const _size1431 = _rtmp31432.size || 0; + for (let _i1433 = 0; _i1433 < _size1431; ++_i1433) { + let key1434 = null; + let val1435 = null; + key1434 = input.readString(); + val1435 = new data_ttypes.TObject(); + val1435.read(input); + val1430[key1434] = val1435; + } + input.readMapEnd(); + this.success[key1429] = val1430; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1436 in this.success) { + if (this.success.hasOwnProperty(kiter1436)) { + let viter1437 = this.success[kiter1436]; + output.writeI64(kiter1436); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1437)); + for (let kiter1438 in viter1437) { + if (viter1437.hasOwnProperty(kiter1438)) { + let viter1439 = viter1437[kiter1438]; + output.writeString(kiter1438); + viter1439.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCriteriaTimestr_args = class { + constructor(args) { + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteriaTimestr_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31441 = input.readMapBegin(); + const _size1440 = _rtmp31441.size || 0; + for (let _i1442 = 0; _i1442 < _size1440; ++_i1442) { + let key1443 = null; + let val1444 = null; + key1443 = input.readI64(); + val1444 = {}; + const _rtmp31446 = input.readMapBegin(); + const _size1445 = _rtmp31446.size || 0; + for (let _i1447 = 0; _i1447 < _size1445; ++_i1447) { + let key1448 = null; + let val1449 = null; + key1448 = input.readString(); + val1449 = new data_ttypes.TObject(); + val1449.read(input); + val1444[key1448] = val1449; + } + input.readMapEnd(); + this.success[key1443] = val1444; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1450 in this.success) { + if (this.success.hasOwnProperty(kiter1450)) { + let viter1451 = this.success[kiter1450]; + output.writeI64(kiter1450); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1451)); + for (let kiter1452 in viter1451) { + if (viter1451.hasOwnProperty(kiter1452)) { + let viter1453 = viter1451[kiter1452]; + output.writeString(kiter1452); + viter1453.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCclTime_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCclTime_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31455 = input.readMapBegin(); + const _size1454 = _rtmp31455.size || 0; + for (let _i1456 = 0; _i1456 < _size1454; ++_i1456) { + let key1457 = null; + let val1458 = null; + key1457 = input.readI64(); + val1458 = {}; + const _rtmp31460 = input.readMapBegin(); + const _size1459 = _rtmp31460.size || 0; + for (let _i1461 = 0; _i1461 < _size1459; ++_i1461) { + let key1462 = null; + let val1463 = null; + key1462 = input.readString(); + val1463 = new data_ttypes.TObject(); + val1463.read(input); + val1458[key1462] = val1463; + } + input.readMapEnd(); + this.success[key1457] = val1458; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1464 in this.success) { + if (this.success.hasOwnProperty(kiter1464)) { + let viter1465 = this.success[kiter1464]; + output.writeI64(kiter1464); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1465)); + for (let kiter1466 in viter1465) { + if (viter1465.hasOwnProperty(kiter1466)) { + let viter1467 = viter1465[kiter1466]; + output.writeString(kiter1466); + viter1467.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCclTimestr_args = class { + constructor(args) { + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCclTimestr_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31469 = input.readMapBegin(); + const _size1468 = _rtmp31469.size || 0; + for (let _i1470 = 0; _i1470 < _size1468; ++_i1470) { + let key1471 = null; + let val1472 = null; + key1471 = input.readI64(); + val1472 = {}; + const _rtmp31474 = input.readMapBegin(); + const _size1473 = _rtmp31474.size || 0; + for (let _i1475 = 0; _i1475 < _size1473; ++_i1475) { + let key1476 = null; + let val1477 = null; + key1476 = input.readString(); + val1477 = new data_ttypes.TObject(); + val1477.read(input); + val1472[key1476] = val1477; + } + input.readMapEnd(); + this.success[key1471] = val1472; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1478 in this.success) { + if (this.success.hasOwnProperty(kiter1478)) { + let viter1479 = this.success[kiter1478]; + output.writeI64(kiter1478); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1479)); + for (let kiter1480 in viter1479) { + if (viter1479.hasOwnProperty(kiter1480)) { + let viter1481 = viter1479[kiter1480]; + output.writeString(kiter1480); + viter1481.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31483 = input.readMapBegin(); + const _size1482 = _rtmp31483.size || 0; + for (let _i1484 = 0; _i1484 < _size1482; ++_i1484) { + let key1485 = null; + let val1486 = null; + key1485 = input.readI64(); + val1486 = new data_ttypes.TObject(); + val1486.read(input); + this.success[key1485] = val1486; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1487 in this.success) { + if (this.success.hasOwnProperty(kiter1487)) { + let viter1488 = this.success[kiter1487]; + output.writeI64(kiter1487); + viter1488.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31490 = input.readMapBegin(); + const _size1489 = _rtmp31490.size || 0; + for (let _i1491 = 0; _i1491 < _size1489; ++_i1491) { + let key1492 = null; + let val1493 = null; + key1492 = input.readI64(); + val1493 = new data_ttypes.TObject(); + val1493.read(input); + this.success[key1492] = val1493; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1494 in this.success) { + if (this.success.hasOwnProperty(kiter1494)) { + let viter1495 = this.success[kiter1494]; + output.writeI64(kiter1494); + viter1495.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31497 = input.readMapBegin(); + const _size1496 = _rtmp31497.size || 0; + for (let _i1498 = 0; _i1498 < _size1496; ++_i1498) { + let key1499 = null; + let val1500 = null; + key1499 = input.readI64(); + val1500 = new data_ttypes.TObject(); + val1500.read(input); + this.success[key1499] = val1500; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1501 in this.success) { + if (this.success.hasOwnProperty(kiter1501)) { + let viter1502 = this.success[kiter1501]; + output.writeI64(kiter1501); + viter1502.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31504 = input.readMapBegin(); + const _size1503 = _rtmp31504.size || 0; + for (let _i1505 = 0; _i1505 < _size1503; ++_i1505) { + let key1506 = null; + let val1507 = null; + key1506 = input.readI64(); + val1507 = new data_ttypes.TObject(); + val1507.read(input); + this.success[key1506] = val1507; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1508 in this.success) { + if (this.success.hasOwnProperty(kiter1508)) { + let viter1509 = this.success[kiter1508]; + output.writeI64(kiter1508); + viter1509.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31511 = input.readMapBegin(); + const _size1510 = _rtmp31511.size || 0; + for (let _i1512 = 0; _i1512 < _size1510; ++_i1512) { + let key1513 = null; + let val1514 = null; + key1513 = input.readI64(); + val1514 = new data_ttypes.TObject(); + val1514.read(input); + this.success[key1513] = val1514; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); + for (let kiter1515 in this.success) { + if (this.success.hasOwnProperty(kiter1515)) { + let viter1516 = this.success[kiter1515]; + output.writeI64(kiter1515); + viter1516.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCriteria_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31518 = input.readListBegin(); + const _size1517 = _rtmp31518.size || 0; + for (let _i1519 = 0; _i1519 < _size1517; ++_i1519) { + let elem1520 = null; + elem1520 = input.readString(); + this.keys.push(elem1520); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteria_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1521 in this.keys) { + if (this.keys.hasOwnProperty(iter1521)) { + iter1521 = this.keys[iter1521]; + output.writeString(iter1521); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31523 = input.readMapBegin(); + const _size1522 = _rtmp31523.size || 0; + for (let _i1524 = 0; _i1524 < _size1522; ++_i1524) { + let key1525 = null; + let val1526 = null; + key1525 = input.readI64(); + val1526 = {}; + const _rtmp31528 = input.readMapBegin(); + const _size1527 = _rtmp31528.size || 0; + for (let _i1529 = 0; _i1529 < _size1527; ++_i1529) { + let key1530 = null; + let val1531 = null; + key1530 = input.readString(); + val1531 = new data_ttypes.TObject(); + val1531.read(input); + val1526[key1530] = val1531; + } + input.readMapEnd(); + this.success[key1525] = val1526; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1532 in this.success) { + if (this.success.hasOwnProperty(kiter1532)) { + let viter1533 = this.success[kiter1532]; + output.writeI64(kiter1532); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1533)); + for (let kiter1534 in viter1533) { + if (viter1533.hasOwnProperty(kiter1534)) { + let viter1535 = viter1533[kiter1534]; + output.writeString(kiter1534); + viter1535.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCcl_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31537 = input.readListBegin(); + const _size1536 = _rtmp31537.size || 0; + for (let _i1538 = 0; _i1538 < _size1536; ++_i1538) { + let elem1539 = null; + elem1539 = input.readString(); + this.keys.push(elem1539); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCcl_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1540 in this.keys) { + if (this.keys.hasOwnProperty(iter1540)) { + iter1540 = this.keys[iter1540]; + output.writeString(iter1540); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31542 = input.readMapBegin(); + const _size1541 = _rtmp31542.size || 0; + for (let _i1543 = 0; _i1543 < _size1541; ++_i1543) { + let key1544 = null; + let val1545 = null; + key1544 = input.readI64(); + val1545 = {}; + const _rtmp31547 = input.readMapBegin(); + const _size1546 = _rtmp31547.size || 0; + for (let _i1548 = 0; _i1548 < _size1546; ++_i1548) { + let key1549 = null; + let val1550 = null; + key1549 = input.readString(); + val1550 = new data_ttypes.TObject(); + val1550.read(input); + val1545[key1549] = val1550; + } + input.readMapEnd(); + this.success[key1544] = val1545; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1551 in this.success) { + if (this.success.hasOwnProperty(kiter1551)) { + let viter1552 = this.success[kiter1551]; + output.writeI64(kiter1551); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1552)); + for (let kiter1553 in viter1552) { + if (viter1552.hasOwnProperty(kiter1553)) { + let viter1554 = viter1552[kiter1553]; + output.writeString(kiter1553); + viter1554.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCriteriaTime_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31556 = input.readListBegin(); + const _size1555 = _rtmp31556.size || 0; + for (let _i1557 = 0; _i1557 < _size1555; ++_i1557) { + let elem1558 = null; + elem1558 = input.readString(); + this.keys.push(elem1558); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteriaTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1559 in this.keys) { + if (this.keys.hasOwnProperty(iter1559)) { + iter1559 = this.keys[iter1559]; + output.writeString(iter1559); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31561 = input.readMapBegin(); + const _size1560 = _rtmp31561.size || 0; + for (let _i1562 = 0; _i1562 < _size1560; ++_i1562) { + let key1563 = null; + let val1564 = null; + key1563 = input.readI64(); + val1564 = {}; + const _rtmp31566 = input.readMapBegin(); + const _size1565 = _rtmp31566.size || 0; + for (let _i1567 = 0; _i1567 < _size1565; ++_i1567) { + let key1568 = null; + let val1569 = null; + key1568 = input.readString(); + val1569 = new data_ttypes.TObject(); + val1569.read(input); + val1564[key1568] = val1569; + } + input.readMapEnd(); + this.success[key1563] = val1564; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1570 in this.success) { + if (this.success.hasOwnProperty(kiter1570)) { + let viter1571 = this.success[kiter1570]; + output.writeI64(kiter1570); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1571)); + for (let kiter1572 in viter1571) { + if (viter1571.hasOwnProperty(kiter1572)) { + let viter1573 = viter1571[kiter1572]; + output.writeString(kiter1572); + viter1573.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCriteriaTimestr_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31575 = input.readListBegin(); + const _size1574 = _rtmp31575.size || 0; + for (let _i1576 = 0; _i1576 < _size1574; ++_i1576) { + let elem1577 = null; + elem1577 = input.readString(); + this.keys.push(elem1577); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteriaTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1578 in this.keys) { + if (this.keys.hasOwnProperty(iter1578)) { + iter1578 = this.keys[iter1578]; + output.writeString(iter1578); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31580 = input.readMapBegin(); + const _size1579 = _rtmp31580.size || 0; + for (let _i1581 = 0; _i1581 < _size1579; ++_i1581) { + let key1582 = null; + let val1583 = null; + key1582 = input.readI64(); + val1583 = {}; + const _rtmp31585 = input.readMapBegin(); + const _size1584 = _rtmp31585.size || 0; + for (let _i1586 = 0; _i1586 < _size1584; ++_i1586) { + let key1587 = null; + let val1588 = null; + key1587 = input.readString(); + val1588 = new data_ttypes.TObject(); + val1588.read(input); + val1583[key1587] = val1588; + } + input.readMapEnd(); + this.success[key1582] = val1583; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1589 in this.success) { + if (this.success.hasOwnProperty(kiter1589)) { + let viter1590 = this.success[kiter1589]; + output.writeI64(kiter1589); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1590)); + for (let kiter1591 in viter1590) { + if (viter1590.hasOwnProperty(kiter1591)) { + let viter1592 = viter1590[kiter1591]; + output.writeString(kiter1591); + viter1592.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCclTime_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31594 = input.readListBegin(); + const _size1593 = _rtmp31594.size || 0; + for (let _i1595 = 0; _i1595 < _size1593; ++_i1595) { + let elem1596 = null; + elem1596 = input.readString(); + this.keys.push(elem1596); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCclTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1597 in this.keys) { + if (this.keys.hasOwnProperty(iter1597)) { + iter1597 = this.keys[iter1597]; + output.writeString(iter1597); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31599 = input.readMapBegin(); + const _size1598 = _rtmp31599.size || 0; + for (let _i1600 = 0; _i1600 < _size1598; ++_i1600) { + let key1601 = null; + let val1602 = null; + key1601 = input.readI64(); + val1602 = {}; + const _rtmp31604 = input.readMapBegin(); + const _size1603 = _rtmp31604.size || 0; + for (let _i1605 = 0; _i1605 < _size1603; ++_i1605) { + let key1606 = null; + let val1607 = null; + key1606 = input.readString(); + val1607 = new data_ttypes.TObject(); + val1607.read(input); + val1602[key1606] = val1607; + } + input.readMapEnd(); + this.success[key1601] = val1602; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1608 in this.success) { + if (this.success.hasOwnProperty(kiter1608)) { + let viter1609 = this.success[kiter1608]; + output.writeI64(kiter1608); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1609)); + for (let kiter1610 in viter1609) { + if (viter1609.hasOwnProperty(kiter1610)) { + let viter1611 = viter1609[kiter1610]; + output.writeString(kiter1610); + viter1611.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCclTimestr_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31613 = input.readListBegin(); + const _size1612 = _rtmp31613.size || 0; + for (let _i1614 = 0; _i1614 < _size1612; ++_i1614) { + let elem1615 = null; + elem1615 = input.readString(); + this.keys.push(elem1615); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCclTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1616 in this.keys) { + if (this.keys.hasOwnProperty(iter1616)) { + iter1616 = this.keys[iter1616]; + output.writeString(iter1616); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getKeysCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31618 = input.readMapBegin(); + const _size1617 = _rtmp31618.size || 0; + for (let _i1619 = 0; _i1619 < _size1617; ++_i1619) { + let key1620 = null; + let val1621 = null; + key1620 = input.readI64(); + val1621 = {}; + const _rtmp31623 = input.readMapBegin(); + const _size1622 = _rtmp31623.size || 0; + for (let _i1624 = 0; _i1624 < _size1622; ++_i1624) { + let key1625 = null; + let val1626 = null; + key1625 = input.readString(); + val1626 = new data_ttypes.TObject(); + val1626.read(input); + val1621[key1625] = val1626; + } + input.readMapEnd(); + this.success[key1620] = val1621; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getKeysCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1627 in this.success) { + if (this.success.hasOwnProperty(kiter1627)) { + let viter1628 = this.success[kiter1627]; + output.writeI64(kiter1627); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1628)); + for (let kiter1629 in viter1628) { + if (viter1628.hasOwnProperty(kiter1629)) { + let viter1630 = viter1628[kiter1629]; + output.writeString(kiter1629); + viter1630.write(output); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyKeyValueRecord_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyKeyValueRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyKeyValueRecordTime_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyKeyValueRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyKeyValueRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyKeyValueRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyKeyValueRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_jsonifyRecords_args = class { + constructor(args) { + this.records = null; + this.identifier = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.identifier !== undefined && args.identifier !== null) { + this.identifier = args.identifier; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31632 = input.readListBegin(); + const _size1631 = _rtmp31632.size || 0; + for (let _i1633 = 0; _i1633 < _size1631; ++_i1633) { + let elem1634 = null; + elem1634 = input.readI64(); + this.records.push(elem1634); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.BOOL) { + this.identifier = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1635 in this.records) { + if (this.records.hasOwnProperty(iter1635)) { + iter1635 = this.records[iter1635]; + output.writeI64(iter1635); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.identifier !== null && this.identifier !== undefined) { + output.writeFieldBegin('identifier', Thrift.Type.BOOL, 2); + output.writeBool(this.identifier); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_jsonifyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRING, 0); + output.writeString(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_jsonifyRecordsTime_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.identifier = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.identifier !== undefined && args.identifier !== null) { + this.identifier = args.identifier; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31637 = input.readListBegin(); + const _size1636 = _rtmp31637.size || 0; + for (let _i1638 = 0; _i1638 < _size1636; ++_i1638) { + let elem1639 = null; + elem1639 = input.readI64(); + this.records.push(elem1639); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.BOOL) { + this.identifier = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecordsTime_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1640 in this.records) { + if (this.records.hasOwnProperty(iter1640)) { + iter1640 = this.records[iter1640]; + output.writeI64(iter1640); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.identifier !== null && this.identifier !== undefined) { + output.writeFieldBegin('identifier', Thrift.Type.BOOL, 3); + output.writeBool(this.identifier); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_jsonifyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRING, 0); + output.writeString(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_jsonifyRecordsTimestr_args = class { + constructor(args) { + this.records = null; + this.timestamp = null; + this.identifier = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.identifier !== undefined && args.identifier !== null) { + this.identifier = args.identifier; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31642 = input.readListBegin(); + const _size1641 = _rtmp31642.size || 0; + for (let _i1643 = 0; _i1643 < _size1641; ++_i1643) { + let elem1644 = null; + elem1644 = input.readI64(); + this.records.push(elem1644); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.BOOL) { + this.identifier = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecordsTimestr_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1645 in this.records) { + if (this.records.hasOwnProperty(iter1645)) { + iter1645 = this.records[iter1645]; + output.writeI64(iter1645); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.identifier !== null && this.identifier !== undefined) { + output.writeFieldBegin('identifier', Thrift.Type.BOOL, 3); + output.writeBool(this.identifier); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_jsonifyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_jsonifyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRING, 0); + output.writeString(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findCriteria_args = class { + constructor(args) { + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findCriteria_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31647 = input.readSetBegin(); + const _size1646 = _rtmp31647.size || 0; + for (let _i1648 = 0; _i1648 < _size1646; ++_i1648) { + let elem1649 = null; + elem1649 = input.readI64(); + this.success.push(elem1649); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1650 in this.success) { + if (this.success.hasOwnProperty(iter1650)) { + iter1650 = this.success[iter1650]; + output.writeI64(iter1650); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findCcl_args = class { + constructor(args) { + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findCcl_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31652 = input.readSetBegin(); + const _size1651 = _rtmp31652.size || 0; + for (let _i1653 = 0; _i1653 < _size1651; ++_i1653) { + let elem1654 = null; + elem1654 = input.readI64(); + this.success.push(elem1654); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1655 in this.success) { + if (this.success.hasOwnProperty(iter1655)) { + iter1655 = this.success[iter1655]; + output.writeI64(iter1655); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorValues_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I32) { + this.operator = input.readI32(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.values = []; + const _rtmp31657 = input.readListBegin(); + const _size1656 = _rtmp31657.size || 0; + for (let _i1658 = 0; _i1658 < _size1656; ++_i1658) { + let elem1659 = null; + elem1659 = new data_ttypes.TObject(); + elem1659.read(input); + this.values.push(elem1659); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValues_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.I32, 2); + output.writeI32(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1660 in this.values) { + if (this.values.hasOwnProperty(iter1660)) { + iter1660 = this.values[iter1660]; + iter1660.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorValues_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31662 = input.readSetBegin(); + const _size1661 = _rtmp31662.size || 0; + for (let _i1663 = 0; _i1663 < _size1661; ++_i1663) { + let elem1664 = null; + elem1664 = input.readI64(); + this.success.push(elem1664); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValues_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1665 in this.success) { + if (this.success.hasOwnProperty(iter1665)) { + iter1665 = this.success[iter1665]; + output.writeI64(iter1665); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorValuesTime_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I32) { + this.operator = input.readI32(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.values = []; + const _rtmp31667 = input.readListBegin(); + const _size1666 = _rtmp31667.size || 0; + for (let _i1668 = 0; _i1668 < _size1666; ++_i1668) { + let elem1669 = null; + elem1669 = new data_ttypes.TObject(); + elem1669.read(input); + this.values.push(elem1669); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValuesTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.I32, 2); + output.writeI32(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1670 in this.values) { + if (this.values.hasOwnProperty(iter1670)) { + iter1670 = this.values[iter1670]; + iter1670.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorValuesTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31672 = input.readSetBegin(); + const _size1671 = _rtmp31672.size || 0; + for (let _i1673 = 0; _i1673 < _size1671; ++_i1673) { + let elem1674 = null; + elem1674 = input.readI64(); + this.success.push(elem1674); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValuesTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1675 in this.success) { + if (this.success.hasOwnProperty(iter1675)) { + iter1675 = this.success[iter1675]; + output.writeI64(iter1675); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorValuesTimestr_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I32) { + this.operator = input.readI32(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.values = []; + const _rtmp31677 = input.readListBegin(); + const _size1676 = _rtmp31677.size || 0; + for (let _i1678 = 0; _i1678 < _size1676; ++_i1678) { + let elem1679 = null; + elem1679 = new data_ttypes.TObject(); + elem1679.read(input); + this.values.push(elem1679); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValuesTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.I32, 2); + output.writeI32(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1680 in this.values) { + if (this.values.hasOwnProperty(iter1680)) { + iter1680 = this.values[iter1680]; + iter1680.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorValuesTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31682 = input.readSetBegin(); + const _size1681 = _rtmp31682.size || 0; + for (let _i1683 = 0; _i1683 < _size1681; ++_i1683) { + let elem1684 = null; + elem1684 = input.readI64(); + this.success.push(elem1684); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorValuesTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1685 in this.success) { + if (this.success.hasOwnProperty(iter1685)) { + iter1685 = this.success[iter1685]; + output.writeI64(iter1685); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorstrValues_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.operator = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.values = []; + const _rtmp31687 = input.readListBegin(); + const _size1686 = _rtmp31687.size || 0; + for (let _i1688 = 0; _i1688 < _size1686; ++_i1688) { + let elem1689 = null; + elem1689 = new data_ttypes.TObject(); + elem1689.read(input); + this.values.push(elem1689); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValues_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.STRING, 2); + output.writeString(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1690 in this.values) { + if (this.values.hasOwnProperty(iter1690)) { + iter1690 = this.values[iter1690]; + iter1690.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorstrValues_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31692 = input.readSetBegin(); + const _size1691 = _rtmp31692.size || 0; + for (let _i1693 = 0; _i1693 < _size1691; ++_i1693) { + let elem1694 = null; + elem1694 = input.readI64(); + this.success.push(elem1694); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValues_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1695 in this.success) { + if (this.success.hasOwnProperty(iter1695)) { + iter1695 = this.success[iter1695]; + output.writeI64(iter1695); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorstrValuesTime_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.operator = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.values = []; + const _rtmp31697 = input.readListBegin(); + const _size1696 = _rtmp31697.size || 0; + for (let _i1698 = 0; _i1698 < _size1696; ++_i1698) { + let elem1699 = null; + elem1699 = new data_ttypes.TObject(); + elem1699.read(input); + this.values.push(elem1699); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.STRING, 2); + output.writeString(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1700 in this.values) { + if (this.values.hasOwnProperty(iter1700)) { + iter1700 = this.values[iter1700]; + iter1700.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorstrValuesTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31702 = input.readSetBegin(); + const _size1701 = _rtmp31702.size || 0; + for (let _i1703 = 0; _i1703 < _size1701; ++_i1703) { + let elem1704 = null; + elem1704 = input.readI64(); + this.success.push(elem1704); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1705 in this.success) { + if (this.success.hasOwnProperty(iter1705)) { + iter1705 = this.success[iter1705]; + output.writeI64(iter1705); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorstrValuesTimestr_args = class { + constructor(args) { + this.key = null; + this.operator = null; + this.values = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.operator !== undefined && args.operator !== null) { + this.operator = args.operator; + } + if (args.values !== undefined && args.values !== null) { + this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.operator = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.values = []; + const _rtmp31707 = input.readListBegin(); + const _size1706 = _rtmp31707.size || 0; + for (let _i1708 = 0; _i1708 < _size1706; ++_i1708) { + let elem1709 = null; + elem1709 = new data_ttypes.TObject(); + elem1709.read(input); + this.values.push(elem1709); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.operator !== null && this.operator !== undefined) { + output.writeFieldBegin('operator', Thrift.Type.STRING, 2); + output.writeString(this.operator); + output.writeFieldEnd(); + } + if (this.values !== null && this.values !== undefined) { + output.writeFieldBegin('values', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.values.length); + for (let iter1710 in this.values) { + if (this.values.hasOwnProperty(iter1710)) { + iter1710 = this.values[iter1710]; + iter1710.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findKeyOperatorstrValuesTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31712 = input.readSetBegin(); + const _size1711 = _rtmp31712.size || 0; + for (let _i1713 = 0; _i1713 < _size1711; ++_i1713) { + let elem1714 = null; + elem1714 = input.readI64(); + this.success.push(elem1714); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1715 in this.success) { + if (this.success.hasOwnProperty(iter1715)) { + iter1715 = this.success[iter1715]; + output.writeI64(iter1715); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_search_args = class { + constructor(args) { + this.key = null; + this.query = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.query !== undefined && args.query !== null) { + this.query = args.query; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.query = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_search_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.query !== null && this.query !== undefined) { + output.writeFieldBegin('query', Thrift.Type.STRING, 2); + output.writeString(this.query); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_search_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyList(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.SET) { + this.success = []; + const _rtmp31717 = input.readSetBegin(); + const _size1716 = _rtmp31717.size || 0; + for (let _i1718 = 0; _i1718 < _size1716; ++_i1718) { + let elem1719 = null; + elem1719 = input.readI64(); + this.success.push(elem1719); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_search_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.SET, 0); + output.writeSetBegin(Thrift.Type.I64, this.success.length); + for (let iter1720 in this.success) { + if (this.success.hasOwnProperty(iter1720)) { + iter1720 = this.success[iter1720]; + output.writeI64(iter1720); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31722 = input.readListBegin(); + const _size1721 = _rtmp31722.size || 0; + for (let _i1723 = 0; _i1723 < _size1721; ++_i1723) { + let elem1724 = null; + elem1724 = input.readString(); + this.keys.push(elem1724); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31726 = input.readListBegin(); + const _size1725 = _rtmp31726.size || 0; + for (let _i1727 = 0; _i1727 < _size1725; ++_i1727) { + let elem1728 = null; + elem1728 = input.readI64(); + this.records.push(elem1728); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1729 in this.keys) { + if (this.keys.hasOwnProperty(iter1729)) { + iter1729 = this.keys[iter1729]; + output.writeString(iter1729); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1730 in this.records) { + if (this.records.hasOwnProperty(iter1730)) { + iter1730 = this.records[iter1730]; + output.writeI64(iter1730); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordsTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordsTime_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31732 = input.readListBegin(); + const _size1731 = _rtmp31732.size || 0; + for (let _i1733 = 0; _i1733 < _size1731; ++_i1733) { + let elem1734 = null; + elem1734 = input.readString(); + this.keys.push(elem1734); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31736 = input.readListBegin(); + const _size1735 = _rtmp31736.size || 0; + for (let _i1737 = 0; _i1737 < _size1735; ++_i1737) { + let elem1738 = null; + elem1738 = input.readI64(); + this.records.push(elem1738); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1739 in this.keys) { + if (this.keys.hasOwnProperty(iter1739)) { + iter1739 = this.keys[iter1739]; + output.writeString(iter1739); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1740 in this.records) { + if (this.records.hasOwnProperty(iter1740)) { + iter1740 = this.records[iter1740]; + output.writeI64(iter1740); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordsTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordsTimestr_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31742 = input.readListBegin(); + const _size1741 = _rtmp31742.size || 0; + for (let _i1743 = 0; _i1743 < _size1741; ++_i1743) { + let elem1744 = null; + elem1744 = input.readString(); + this.keys.push(elem1744); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1745 in this.keys) { + if (this.keys.hasOwnProperty(iter1745)) { + iter1745 = this.keys[iter1745]; + output.writeString(iter1745); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordTime_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31747 = input.readListBegin(); + const _size1746 = _rtmp31747.size || 0; + for (let _i1748 = 0; _i1748 < _size1746; ++_i1748) { + let elem1749 = null; + elem1749 = input.readString(); + this.keys.push(elem1749); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1750 in this.keys) { + if (this.keys.hasOwnProperty(iter1750)) { + iter1750 = this.keys[iter1750]; + output.writeString(iter1750); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeysRecordTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeysRecordTimestr_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31752 = input.readListBegin(); + const _size1751 = _rtmp31752.size || 0; + for (let _i1753 = 0; _i1753 < _size1751; ++_i1753) { + let elem1754 = null; + elem1754 = input.readI64(); + this.records.push(elem1754); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1755 in this.records) { + if (this.records.hasOwnProperty(iter1755)) { + iter1755 = this.records[iter1755]; + output.writeI64(iter1755); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordsTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordsTime_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31757 = input.readListBegin(); + const _size1756 = _rtmp31757.size || 0; + for (let _i1758 = 0; _i1758 < _size1756; ++_i1758) { + let elem1759 = null; + elem1759 = input.readI64(); + this.records.push(elem1759); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1760 in this.records) { + if (this.records.hasOwnProperty(iter1760)) { + iter1760 = this.records[iter1760]; + output.writeI64(iter1760); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordsTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordsTimestr_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordTime_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordTime_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_revertKeyRecordTimestr_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_revertKeyRecordTimestr_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_pingRecords_args = class { + constructor(args) { + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31762 = input.readListBegin(); + const _size1761 = _rtmp31762.size || 0; + for (let _i1763 = 0; _i1763 < _size1761; ++_i1763) { + let elem1764 = null; + elem1764 = input.readI64(); + this.records.push(elem1764); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_pingRecords_args'); + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1765 in this.records) { + if (this.records.hasOwnProperty(iter1765)) { + iter1765 = this.records[iter1765]; + output.writeI64(iter1765); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_pingRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [null]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31767 = input.readMapBegin(); + const _size1766 = _rtmp31767.size || 0; + for (let _i1768 = 0; _i1768 < _size1766; ++_i1768) { + let key1769 = null; + let val1770 = null; + key1769 = input.readI64(); + val1770 = input.readBool(); + this.success[key1769] = val1770; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_pingRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); + for (let kiter1771 in this.success) { + if (this.success.hasOwnProperty(kiter1771)) { + let viter1772 = this.success[kiter1771]; + output.writeI64(kiter1771); + output.writeBool(viter1772); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_pingRecord_args = class { + constructor(args) { + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_pingRecord_args'); + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 1); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_pingRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_pingRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyAndSwap_args = class { + constructor(args) { + this.key = null; + this.expected = null; + this.record = null; + this.replacement = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.expected !== undefined && args.expected !== null) { + this.expected = new data_ttypes.TObject(args.expected); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.replacement !== undefined && args.replacement !== null) { + this.replacement = new data_ttypes.TObject(args.replacement); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.expected = new data_ttypes.TObject(); + this.expected.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.replacement = new data_ttypes.TObject(); + this.replacement.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyAndSwap_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.expected !== null && this.expected !== undefined) { + output.writeFieldBegin('expected', Thrift.Type.STRUCT, 2); + this.expected.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.replacement !== null && this.replacement !== undefined) { + output.writeFieldBegin('replacement', Thrift.Type.STRUCT, 4); + this.replacement.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 7); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyAndSwap_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.BOOL) { + this.success = input.readBool(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyAndSwap_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.BOOL, 0); + output.writeBool(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyOrSet_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyOrSet_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 3); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_verifyOrSet_result = class { + constructor(args) { + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.InvalidArgumentException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_verifyOrSet_result'); + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findOrAddKeyValue_args = class { + constructor(args) { + this.key = null; + this.value = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.value !== undefined && args.value !== null) { + this.value = new data_ttypes.TObject(args.value); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.value = new data_ttypes.TObject(); + this.value.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrAddKeyValue_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.value !== null && this.value !== undefined) { + output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); + this.value.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findOrAddKeyValue_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.DuplicateEntryException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.InvalidArgumentException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.DuplicateEntryException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.InvalidArgumentException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrAddKeyValue_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + if (this.ex5 !== null && this.ex5 !== undefined) { + output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); + this.ex5.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findOrInsertCriteriaJson_args = class { + constructor(args) { + this.criteria = null; + this.json = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.json = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrInsertCriteriaJson_args'); + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 2); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findOrInsertCriteriaJson_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.DuplicateEntryException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.DuplicateEntryException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrInsertCriteriaJson_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findOrInsertCclJson_args = class { + constructor(args) { + this.ccl = null; + this.json = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.json !== undefined && args.json !== null) { + this.json = args.json; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.json = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrInsertCclJson_args'); + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.json !== null && this.json !== undefined) { + output.writeFieldBegin('json', Thrift.Type.STRING, 2); + output.writeString(this.json); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_findOrInsertCclJson_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + this.ex5 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.DuplicateEntryException) { + this.ex4 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex5 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + if (args.ex5 !== undefined && args.ex5 !== null) { + this.ex5 = args.ex5; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.DuplicateEntryException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.ex5 = new exceptions_ttypes.PermissionException(); + this.ex5.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_findOrInsertCclJson_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + if (this.ex5 !== null && this.ex5 !== undefined) { + output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); + this.ex5.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31774 = input.readListBegin(); + const _size1773 = _rtmp31774.size || 0; + for (let _i1775 = 0; _i1775 < _size1773; ++_i1775) { + let elem1776 = null; + elem1776 = input.readI64(); + this.records.push(elem1776); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1777 in this.records) { + if (this.records.hasOwnProperty(iter1777)) { + iter1777 = this.records[iter1777]; + output.writeI64(iter1777); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31779 = input.readListBegin(); + const _size1778 = _rtmp31779.size || 0; + for (let _i1780 = 0; _i1780 < _size1778; ++_i1780) { + let elem1781 = null; + elem1781 = input.readI64(); + this.records.push(elem1781); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1782 in this.records) { + if (this.records.hasOwnProperty(iter1782)) { + iter1782 = this.records[iter1782]; + output.writeI64(iter1782); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31784 = input.readListBegin(); + const _size1783 = _rtmp31784.size || 0; + for (let _i1785 = 0; _i1785 < _size1783; ++_i1785) { + let elem1786 = null; + elem1786 = input.readI64(); + this.records.push(elem1786); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1787 in this.records) { + if (this.records.hasOwnProperty(iter1787)) { + iter1787 = this.records[iter1787]; + output.writeI64(iter1787); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKey_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_sumKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_sumKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31789 = input.readListBegin(); + const _size1788 = _rtmp31789.size || 0; + for (let _i1790 = 0; _i1790 < _size1788; ++_i1790) { + let elem1791 = null; + elem1791 = input.readI64(); + this.records.push(elem1791); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1792 in this.records) { + if (this.records.hasOwnProperty(iter1792)) { + iter1792 = this.records[iter1792]; + output.writeI64(iter1792); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31794 = input.readListBegin(); + const _size1793 = _rtmp31794.size || 0; + for (let _i1795 = 0; _i1795 < _size1793; ++_i1795) { + let elem1796 = null; + elem1796 = input.readI64(); + this.records.push(elem1796); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1797 in this.records) { + if (this.records.hasOwnProperty(iter1797)) { + iter1797 = this.records[iter1797]; + output.writeI64(iter1797); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31799 = input.readListBegin(); + const _size1798 = _rtmp31799.size || 0; + for (let _i1800 = 0; _i1800 < _size1798; ++_i1800) { + let elem1801 = null; + elem1801 = input.readI64(); + this.records.push(elem1801); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1802 in this.records) { + if (this.records.hasOwnProperty(iter1802)) { + iter1802 = this.records[iter1802]; + output.writeI64(iter1802); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKey_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_averageKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_averageKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31804 = input.readListBegin(); + const _size1803 = _rtmp31804.size || 0; + for (let _i1805 = 0; _i1805 < _size1803; ++_i1805) { + let elem1806 = null; + elem1806 = input.readI64(); + this.records.push(elem1806); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1807 in this.records) { + if (this.records.hasOwnProperty(iter1807)) { + iter1807 = this.records[iter1807]; + output.writeI64(iter1807); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31809 = input.readListBegin(); + const _size1808 = _rtmp31809.size || 0; + for (let _i1810 = 0; _i1810 < _size1808; ++_i1810) { + let elem1811 = null; + elem1811 = input.readI64(); + this.records.push(elem1811); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1812 in this.records) { + if (this.records.hasOwnProperty(iter1812)) { + iter1812 = this.records[iter1812]; + output.writeI64(iter1812); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31814 = input.readListBegin(); + const _size1813 = _rtmp31814.size || 0; + for (let _i1815 = 0; _i1815 < _size1813; ++_i1815) { + let elem1816 = null; + elem1816 = input.readI64(); + this.records.push(elem1816); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1817 in this.records) { + if (this.records.hasOwnProperty(iter1817)) { + iter1817 = this.records[iter1817]; + output.writeI64(iter1817); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKey_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_countKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_countKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31819 = input.readListBegin(); + const _size1818 = _rtmp31819.size || 0; + for (let _i1820 = 0; _i1820 < _size1818; ++_i1820) { + let elem1821 = null; + elem1821 = input.readI64(); + this.records.push(elem1821); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1822 in this.records) { + if (this.records.hasOwnProperty(iter1822)) { + iter1822 = this.records[iter1822]; + output.writeI64(iter1822); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31824 = input.readListBegin(); + const _size1823 = _rtmp31824.size || 0; + for (let _i1825 = 0; _i1825 < _size1823; ++_i1825) { + let elem1826 = null; + elem1826 = input.readI64(); + this.records.push(elem1826); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1827 in this.records) { + if (this.records.hasOwnProperty(iter1827)) { + iter1827 = this.records[iter1827]; + output.writeI64(iter1827); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31829 = input.readListBegin(); + const _size1828 = _rtmp31829.size || 0; + for (let _i1830 = 0; _i1830 < _size1828; ++_i1830) { + let elem1831 = null; + elem1831 = input.readI64(); + this.records.push(elem1831); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1832 in this.records) { + if (this.records.hasOwnProperty(iter1832)) { + iter1832 = this.records[iter1832]; + output.writeI64(iter1832); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKey_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_maxKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_maxKeyTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKey_args = class { + constructor(args) { + this.key = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKey_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKey_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKey_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31834 = input.readListBegin(); + const _size1833 = _rtmp31834.size || 0; + for (let _i1835 = 0; _i1835 < _size1833; ++_i1835) { + let elem1836 = null; + elem1836 = input.readI64(); + this.records.push(elem1836); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1837 in this.records) { + if (this.records.hasOwnProperty(iter1837)) { + iter1837 = this.records[iter1837]; + output.writeI64(iter1837); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31839 = input.readListBegin(); + const _size1838 = _rtmp31839.size || 0; + for (let _i1840 = 0; _i1840 < _size1838; ++_i1840) { + let elem1841 = null; + elem1841 = input.readI64(); + this.records.push(elem1841); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1842 in this.records) { + if (this.records.hasOwnProperty(iter1842)) { + iter1842 = this.records[iter1842]; + output.writeI64(iter1842); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyTime_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyTimestr_args = class { + constructor(args) { + this.key = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31844 = input.readListBegin(); + const _size1843 = _rtmp31844.size || 0; + for (let _i1845 = 0; _i1845 < _size1843; ++_i1845) { + let elem1846 = null; + elem1846 = input.readI64(); + this.records.push(elem1846); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1847 in this.records) { + if (this.records.hasOwnProperty(iter1847)) { + iter1847 = this.records[iter1847]; + output.writeI64(iter1847); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_minKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new data_ttypes.TObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new data_ttypes.TObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_minKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecord_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecord_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31849 = input.readMapBegin(); + const _size1848 = _rtmp31849.size || 0; + for (let _i1850 = 0; _i1850 < _size1848; ++_i1850) { + let key1851 = null; + let val1852 = null; + key1851 = input.readI64(); + val1852 = []; + const _rtmp31854 = input.readSetBegin(); + const _size1853 = _rtmp31854.size || 0; + for (let _i1855 = 0; _i1855 < _size1853; ++_i1855) { + let elem1856 = null; + elem1856 = new data_ttypes.TObject(); + elem1856.read(input); + val1852.push(elem1856); + } + input.readSetEnd(); + this.success[key1851] = val1852; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1857 in this.success) { + if (this.success.hasOwnProperty(kiter1857)) { + let viter1858 = this.success[kiter1857]; + output.writeI64(kiter1857); + output.writeSetBegin(Thrift.Type.STRUCT, viter1858.length); + for (let iter1859 in viter1858) { + if (viter1858.hasOwnProperty(iter1859)) { + iter1859 = viter1858[iter1859]; + iter1859.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordTime_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31861 = input.readMapBegin(); + const _size1860 = _rtmp31861.size || 0; + for (let _i1862 = 0; _i1862 < _size1860; ++_i1862) { + let key1863 = null; + let val1864 = null; + key1863 = input.readI64(); + val1864 = []; + const _rtmp31866 = input.readSetBegin(); + const _size1865 = _rtmp31866.size || 0; + for (let _i1867 = 0; _i1867 < _size1865; ++_i1867) { + let elem1868 = null; + elem1868 = new data_ttypes.TObject(); + elem1868.read(input); + val1864.push(elem1868); + } + input.readSetEnd(); + this.success[key1863] = val1864; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1869 in this.success) { + if (this.success.hasOwnProperty(kiter1869)) { + let viter1870 = this.success[kiter1869]; + output.writeI64(kiter1869); + output.writeSetBegin(Thrift.Type.STRUCT, viter1870.length); + for (let iter1871 in viter1870) { + if (viter1870.hasOwnProperty(iter1871)) { + iter1871 = viter1870[iter1871]; + iter1871.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordTimestr_args = class { + constructor(args) { + this.key = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31873 = input.readMapBegin(); + const _size1872 = _rtmp31873.size || 0; + for (let _i1874 = 0; _i1874 < _size1872; ++_i1874) { + let key1875 = null; + let val1876 = null; + key1875 = input.readI64(); + val1876 = []; + const _rtmp31878 = input.readSetBegin(); + const _size1877 = _rtmp31878.size || 0; + for (let _i1879 = 0; _i1879 < _size1877; ++_i1879) { + let elem1880 = null; + elem1880 = new data_ttypes.TObject(); + elem1880.read(input); + val1876.push(elem1880); + } + input.readSetEnd(); + this.success[key1875] = val1876; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1881 in this.success) { + if (this.success.hasOwnProperty(kiter1881)) { + let viter1882 = this.success[kiter1881]; + output.writeI64(kiter1881); + output.writeSetBegin(Thrift.Type.STRUCT, viter1882.length); + for (let iter1883 in viter1882) { + if (viter1882.hasOwnProperty(iter1883)) { + iter1883 = viter1882[iter1883]; + iter1883.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecord_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31885 = input.readListBegin(); + const _size1884 = _rtmp31885.size || 0; + for (let _i1886 = 0; _i1886 < _size1884; ++_i1886) { + let elem1887 = null; + elem1887 = input.readString(); + this.keys.push(elem1887); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecord_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1888 in this.keys) { + if (this.keys.hasOwnProperty(iter1888)) { + iter1888 = this.keys[iter1888]; + output.writeString(iter1888); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecord_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31890 = input.readMapBegin(); + const _size1889 = _rtmp31890.size || 0; + for (let _i1891 = 0; _i1891 < _size1889; ++_i1891) { + let key1892 = null; + let val1893 = null; + key1892 = input.readI64(); + val1893 = {}; + const _rtmp31895 = input.readMapBegin(); + const _size1894 = _rtmp31895.size || 0; + for (let _i1896 = 0; _i1896 < _size1894; ++_i1896) { + let key1897 = null; + let val1898 = null; + key1897 = input.readString(); + val1898 = []; + const _rtmp31900 = input.readSetBegin(); + const _size1899 = _rtmp31900.size || 0; + for (let _i1901 = 0; _i1901 < _size1899; ++_i1901) { + let elem1902 = null; + elem1902 = new data_ttypes.TObject(); + elem1902.read(input); + val1898.push(elem1902); + } + input.readSetEnd(); + val1893[key1897] = val1898; + } + input.readMapEnd(); + this.success[key1892] = val1893; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecord_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1903 in this.success) { + if (this.success.hasOwnProperty(kiter1903)) { + let viter1904 = this.success[kiter1903]; + output.writeI64(kiter1903); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1904)); + for (let kiter1905 in viter1904) { + if (viter1904.hasOwnProperty(kiter1905)) { + let viter1906 = viter1904[kiter1905]; + output.writeString(kiter1905); + output.writeSetBegin(Thrift.Type.STRUCT, viter1906.length); + for (let iter1907 in viter1906) { + if (viter1906.hasOwnProperty(iter1907)) { + iter1907 = viter1906[iter1907]; + iter1907.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordTime_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31909 = input.readListBegin(); + const _size1908 = _rtmp31909.size || 0; + for (let _i1910 = 0; _i1910 < _size1908; ++_i1910) { + let elem1911 = null; + elem1911 = input.readString(); + this.keys.push(elem1911); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1912 in this.keys) { + if (this.keys.hasOwnProperty(iter1912)) { + iter1912 = this.keys[iter1912]; + output.writeString(iter1912); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31914 = input.readMapBegin(); + const _size1913 = _rtmp31914.size || 0; + for (let _i1915 = 0; _i1915 < _size1913; ++_i1915) { + let key1916 = null; + let val1917 = null; + key1916 = input.readI64(); + val1917 = {}; + const _rtmp31919 = input.readMapBegin(); + const _size1918 = _rtmp31919.size || 0; + for (let _i1920 = 0; _i1920 < _size1918; ++_i1920) { + let key1921 = null; + let val1922 = null; + key1921 = input.readString(); + val1922 = []; + const _rtmp31924 = input.readSetBegin(); + const _size1923 = _rtmp31924.size || 0; + for (let _i1925 = 0; _i1925 < _size1923; ++_i1925) { + let elem1926 = null; + elem1926 = new data_ttypes.TObject(); + elem1926.read(input); + val1922.push(elem1926); + } + input.readSetEnd(); + val1917[key1921] = val1922; + } + input.readMapEnd(); + this.success[key1916] = val1917; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1927 in this.success) { + if (this.success.hasOwnProperty(kiter1927)) { + let viter1928 = this.success[kiter1927]; + output.writeI64(kiter1927); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1928)); + for (let kiter1929 in viter1928) { + if (viter1928.hasOwnProperty(kiter1929)) { + let viter1930 = viter1928[kiter1929]; + output.writeString(kiter1929); + output.writeSetBegin(Thrift.Type.STRUCT, viter1930.length); + for (let iter1931 in viter1930) { + if (viter1930.hasOwnProperty(iter1931)) { + iter1931 = viter1930[iter1931]; + iter1931.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordTimestr_args = class { + constructor(args) { + this.keys = null; + this.record = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.record !== undefined && args.record !== null) { + this.record = args.record; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31933 = input.readListBegin(); + const _size1932 = _rtmp31933.size || 0; + for (let _i1934 = 0; _i1934 < _size1932; ++_i1934) { + let elem1935 = null; + elem1935 = input.readString(); + this.keys.push(elem1935); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.record = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1936 in this.keys) { + if (this.keys.hasOwnProperty(iter1936)) { + iter1936 = this.keys[iter1936]; + output.writeString(iter1936); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.record !== null && this.record !== undefined) { + output.writeFieldBegin('record', Thrift.Type.I64, 2); + output.writeI64(this.record); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31938 = input.readMapBegin(); + const _size1937 = _rtmp31938.size || 0; + for (let _i1939 = 0; _i1939 < _size1937; ++_i1939) { + let key1940 = null; + let val1941 = null; + key1940 = input.readI64(); + val1941 = {}; + const _rtmp31943 = input.readMapBegin(); + const _size1942 = _rtmp31943.size || 0; + for (let _i1944 = 0; _i1944 < _size1942; ++_i1944) { + let key1945 = null; + let val1946 = null; + key1945 = input.readString(); + val1946 = []; + const _rtmp31948 = input.readSetBegin(); + const _size1947 = _rtmp31948.size || 0; + for (let _i1949 = 0; _i1949 < _size1947; ++_i1949) { + let elem1950 = null; + elem1950 = new data_ttypes.TObject(); + elem1950.read(input); + val1946.push(elem1950); + } + input.readSetEnd(); + val1941[key1945] = val1946; + } + input.readMapEnd(); + this.success[key1940] = val1941; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1951 in this.success) { + if (this.success.hasOwnProperty(kiter1951)) { + let viter1952 = this.success[kiter1951]; + output.writeI64(kiter1951); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1952)); + for (let kiter1953 in viter1952) { + if (viter1952.hasOwnProperty(kiter1953)) { + let viter1954 = viter1952[kiter1953]; + output.writeString(kiter1953); + output.writeSetBegin(Thrift.Type.STRUCT, viter1954.length); + for (let iter1955 in viter1954) { + if (viter1954.hasOwnProperty(iter1955)) { + iter1955 = viter1954[iter1955]; + iter1955.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecords_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp31957 = input.readListBegin(); + const _size1956 = _rtmp31957.size || 0; + for (let _i1958 = 0; _i1958 < _size1956; ++_i1958) { + let elem1959 = null; + elem1959 = input.readString(); + this.keys.push(elem1959); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31961 = input.readListBegin(); + const _size1960 = _rtmp31961.size || 0; + for (let _i1962 = 0; _i1962 < _size1960; ++_i1962) { + let elem1963 = null; + elem1963 = input.readI64(); + this.records.push(elem1963); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecords_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter1964 in this.keys) { + if (this.keys.hasOwnProperty(iter1964)) { + iter1964 = this.keys[iter1964]; + output.writeString(iter1964); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1965 in this.records) { + if (this.records.hasOwnProperty(iter1965)) { + iter1965 = this.records[iter1965]; + output.writeI64(iter1965); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31967 = input.readMapBegin(); + const _size1966 = _rtmp31967.size || 0; + for (let _i1968 = 0; _i1968 < _size1966; ++_i1968) { + let key1969 = null; + let val1970 = null; + key1969 = input.readI64(); + val1970 = {}; + const _rtmp31972 = input.readMapBegin(); + const _size1971 = _rtmp31972.size || 0; + for (let _i1973 = 0; _i1973 < _size1971; ++_i1973) { + let key1974 = null; + let val1975 = null; + key1974 = input.readString(); + val1975 = []; + const _rtmp31977 = input.readSetBegin(); + const _size1976 = _rtmp31977.size || 0; + for (let _i1978 = 0; _i1978 < _size1976; ++_i1978) { + let elem1979 = null; + elem1979 = new data_ttypes.TObject(); + elem1979.read(input); + val1975.push(elem1979); + } + input.readSetEnd(); + val1970[key1974] = val1975; + } + input.readMapEnd(); + this.success[key1969] = val1970; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter1980 in this.success) { + if (this.success.hasOwnProperty(kiter1980)) { + let viter1981 = this.success[kiter1980]; + output.writeI64(kiter1980); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1981)); + for (let kiter1982 in viter1981) { + if (viter1981.hasOwnProperty(kiter1982)) { + let viter1983 = viter1981[kiter1982]; + output.writeString(kiter1982); + output.writeSetBegin(Thrift.Type.STRUCT, viter1983.length); + for (let iter1984 in viter1983) { + if (viter1983.hasOwnProperty(iter1984)) { + iter1984 = viter1983[iter1984]; + iter1984.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecords_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp31986 = input.readListBegin(); + const _size1985 = _rtmp31986.size || 0; + for (let _i1987 = 0; _i1987 < _size1985; ++_i1987) { + let elem1988 = null; + elem1988 = input.readI64(); + this.records.push(elem1988); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecords_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter1989 in this.records) { + if (this.records.hasOwnProperty(iter1989)) { + iter1989 = this.records[iter1989]; + output.writeI64(iter1989); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecords_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp31991 = input.readMapBegin(); + const _size1990 = _rtmp31991.size || 0; + for (let _i1992 = 0; _i1992 < _size1990; ++_i1992) { + let key1993 = null; + let val1994 = null; + key1993 = input.readI64(); + val1994 = []; + const _rtmp31996 = input.readSetBegin(); + const _size1995 = _rtmp31996.size || 0; + for (let _i1997 = 0; _i1997 < _size1995; ++_i1997) { + let elem1998 = null; + elem1998 = new data_ttypes.TObject(); + elem1998.read(input); + val1994.push(elem1998); + } + input.readSetEnd(); + this.success[key1993] = val1994; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecords_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter1999 in this.success) { + if (this.success.hasOwnProperty(kiter1999)) { + let viter2000 = this.success[kiter1999]; + output.writeI64(kiter1999); + output.writeSetBegin(Thrift.Type.STRUCT, viter2000.length); + for (let iter2001 in viter2000) { + if (viter2000.hasOwnProperty(iter2001)) { + iter2001 = viter2000[iter2001]; + iter2001.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordsTime_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp32003 = input.readListBegin(); + const _size2002 = _rtmp32003.size || 0; + for (let _i2004 = 0; _i2004 < _size2002; ++_i2004) { + let elem2005 = null; + elem2005 = input.readI64(); + this.records.push(elem2005); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordsTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2006 in this.records) { + if (this.records.hasOwnProperty(iter2006)) { + iter2006 = this.records[iter2006]; + output.writeI64(iter2006); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32008 = input.readMapBegin(); + const _size2007 = _rtmp32008.size || 0; + for (let _i2009 = 0; _i2009 < _size2007; ++_i2009) { + let key2010 = null; + let val2011 = null; + key2010 = input.readI64(); + val2011 = []; + const _rtmp32013 = input.readSetBegin(); + const _size2012 = _rtmp32013.size || 0; + for (let _i2014 = 0; _i2014 < _size2012; ++_i2014) { + let elem2015 = null; + elem2015 = new data_ttypes.TObject(); + elem2015.read(input); + val2011.push(elem2015); + } + input.readSetEnd(); + this.success[key2010] = val2011; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2016 in this.success) { + if (this.success.hasOwnProperty(kiter2016)) { + let viter2017 = this.success[kiter2016]; + output.writeI64(kiter2016); + output.writeSetBegin(Thrift.Type.STRUCT, viter2017.length); + for (let iter2018 in viter2017) { + if (viter2017.hasOwnProperty(iter2018)) { + iter2018 = viter2017[iter2018]; + iter2018.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordsTimestr_args = class { + constructor(args) { + this.key = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp32020 = input.readListBegin(); + const _size2019 = _rtmp32020.size || 0; + for (let _i2021 = 0; _i2021 < _size2019; ++_i2021) { + let elem2022 = null; + elem2022 = input.readI64(); + this.records.push(elem2022); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordsTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2023 in this.records) { + if (this.records.hasOwnProperty(iter2023)) { + iter2023 = this.records[iter2023]; + output.writeI64(iter2023); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32025 = input.readMapBegin(); + const _size2024 = _rtmp32025.size || 0; + for (let _i2026 = 0; _i2026 < _size2024; ++_i2026) { + let key2027 = null; + let val2028 = null; + key2027 = input.readI64(); + val2028 = []; + const _rtmp32030 = input.readSetBegin(); + const _size2029 = _rtmp32030.size || 0; + for (let _i2031 = 0; _i2031 < _size2029; ++_i2031) { + let elem2032 = null; + elem2032 = new data_ttypes.TObject(); + elem2032.read(input); + val2028.push(elem2032); + } + input.readSetEnd(); + this.success[key2027] = val2028; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2033 in this.success) { + if (this.success.hasOwnProperty(kiter2033)) { + let viter2034 = this.success[kiter2033]; + output.writeI64(kiter2033); + output.writeSetBegin(Thrift.Type.STRUCT, viter2034.length); + for (let iter2035 in viter2034) { + if (viter2034.hasOwnProperty(iter2035)) { + iter2035 = viter2034[iter2035]; + iter2035.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordsTime_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32037 = input.readListBegin(); + const _size2036 = _rtmp32037.size || 0; + for (let _i2038 = 0; _i2038 < _size2036; ++_i2038) { + let elem2039 = null; + elem2039 = input.readString(); + this.keys.push(elem2039); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp32041 = input.readListBegin(); + const _size2040 = _rtmp32041.size || 0; + for (let _i2042 = 0; _i2042 < _size2040; ++_i2042) { + let elem2043 = null; + elem2043 = input.readI64(); + this.records.push(elem2043); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordsTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2044 in this.keys) { + if (this.keys.hasOwnProperty(iter2044)) { + iter2044 = this.keys[iter2044]; + output.writeString(iter2044); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2045 in this.records) { + if (this.records.hasOwnProperty(iter2045)) { + iter2045 = this.records[iter2045]; + output.writeI64(iter2045); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordsTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32047 = input.readMapBegin(); + const _size2046 = _rtmp32047.size || 0; + for (let _i2048 = 0; _i2048 < _size2046; ++_i2048) { + let key2049 = null; + let val2050 = null; + key2049 = input.readI64(); + val2050 = {}; + const _rtmp32052 = input.readMapBegin(); + const _size2051 = _rtmp32052.size || 0; + for (let _i2053 = 0; _i2053 < _size2051; ++_i2053) { + let key2054 = null; + let val2055 = null; + key2054 = input.readString(); + val2055 = []; + const _rtmp32057 = input.readSetBegin(); + const _size2056 = _rtmp32057.size || 0; + for (let _i2058 = 0; _i2058 < _size2056; ++_i2058) { + let elem2059 = null; + elem2059 = new data_ttypes.TObject(); + elem2059.read(input); + val2055.push(elem2059); + } + input.readSetEnd(); + val2050[key2054] = val2055; + } + input.readMapEnd(); + this.success[key2049] = val2050; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordsTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2060 in this.success) { + if (this.success.hasOwnProperty(kiter2060)) { + let viter2061 = this.success[kiter2060]; + output.writeI64(kiter2060); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2061)); + for (let kiter2062 in viter2061) { + if (viter2061.hasOwnProperty(kiter2062)) { + let viter2063 = viter2061[kiter2062]; + output.writeString(kiter2062); + output.writeSetBegin(Thrift.Type.STRUCT, viter2063.length); + for (let iter2064 in viter2063) { + if (viter2063.hasOwnProperty(iter2064)) { + iter2064 = viter2063[iter2064]; + iter2064.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordsTimestr_args = class { + constructor(args) { + this.keys = null; + this.records = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.records !== undefined && args.records !== null) { + this.records = Thrift.copyList(args.records, [null]); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32066 = input.readListBegin(); + const _size2065 = _rtmp32066.size || 0; + for (let _i2067 = 0; _i2067 < _size2065; ++_i2067) { + let elem2068 = null; + elem2068 = input.readString(); + this.keys.push(elem2068); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.LIST) { + this.records = []; + const _rtmp32070 = input.readListBegin(); + const _size2069 = _rtmp32070.size || 0; + for (let _i2071 = 0; _i2071 < _size2069; ++_i2071) { + let elem2072 = null; + elem2072 = input.readI64(); + this.records.push(elem2072); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordsTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2073 in this.keys) { + if (this.keys.hasOwnProperty(iter2073)) { + iter2073 = this.keys[iter2073]; + output.writeString(iter2073); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.records !== null && this.records !== undefined) { + output.writeFieldBegin('records', Thrift.Type.LIST, 2); + output.writeListBegin(Thrift.Type.I64, this.records.length); + for (let iter2074 in this.records) { + if (this.records.hasOwnProperty(iter2074)) { + iter2074 = this.records[iter2074]; + output.writeI64(iter2074); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysRecordsTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32076 = input.readMapBegin(); + const _size2075 = _rtmp32076.size || 0; + for (let _i2077 = 0; _i2077 < _size2075; ++_i2077) { + let key2078 = null; + let val2079 = null; + key2078 = input.readI64(); + val2079 = {}; + const _rtmp32081 = input.readMapBegin(); + const _size2080 = _rtmp32081.size || 0; + for (let _i2082 = 0; _i2082 < _size2080; ++_i2082) { + let key2083 = null; + let val2084 = null; + key2083 = input.readString(); + val2084 = []; + const _rtmp32086 = input.readSetBegin(); + const _size2085 = _rtmp32086.size || 0; + for (let _i2087 = 0; _i2087 < _size2085; ++_i2087) { + let elem2088 = null; + elem2088 = new data_ttypes.TObject(); + elem2088.read(input); + val2084.push(elem2088); + } + input.readSetEnd(); + val2079[key2083] = val2084; + } + input.readMapEnd(); + this.success[key2078] = val2079; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysRecordsTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2089 in this.success) { + if (this.success.hasOwnProperty(kiter2089)) { + let viter2090 = this.success[kiter2089]; + output.writeI64(kiter2089); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2090)); + for (let kiter2091 in viter2090) { + if (viter2090.hasOwnProperty(kiter2091)) { + let viter2092 = viter2090[kiter2091]; + output.writeString(kiter2091); + output.writeSetBegin(Thrift.Type.STRUCT, viter2092.length); + for (let iter2093 in viter2092) { + if (viter2092.hasOwnProperty(iter2093)) { + iter2093 = viter2092[iter2093]; + iter2093.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCcl_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCcl_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32095 = input.readMapBegin(); + const _size2094 = _rtmp32095.size || 0; + for (let _i2096 = 0; _i2096 < _size2094; ++_i2096) { + let key2097 = null; + let val2098 = null; + key2097 = input.readI64(); + val2098 = []; + const _rtmp32100 = input.readSetBegin(); + const _size2099 = _rtmp32100.size || 0; + for (let _i2101 = 0; _i2101 < _size2099; ++_i2101) { + let elem2102 = null; + elem2102 = new data_ttypes.TObject(); + elem2102.read(input); + val2098.push(elem2102); + } + input.readSetEnd(); + this.success[key2097] = val2098; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2103 in this.success) { + if (this.success.hasOwnProperty(kiter2103)) { + let viter2104 = this.success[kiter2103]; + output.writeI64(kiter2103); + output.writeSetBegin(Thrift.Type.STRUCT, viter2104.length); + for (let iter2105 in viter2104) { + if (viter2104.hasOwnProperty(iter2105)) { + iter2105 = viter2104[iter2105]; + iter2105.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCclTime_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCclTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32107 = input.readMapBegin(); + const _size2106 = _rtmp32107.size || 0; + for (let _i2108 = 0; _i2108 < _size2106; ++_i2108) { + let key2109 = null; + let val2110 = null; + key2109 = input.readI64(); + val2110 = []; + const _rtmp32112 = input.readSetBegin(); + const _size2111 = _rtmp32112.size || 0; + for (let _i2113 = 0; _i2113 < _size2111; ++_i2113) { + let elem2114 = null; + elem2114 = new data_ttypes.TObject(); + elem2114.read(input); + val2110.push(elem2114); + } + input.readSetEnd(); + this.success[key2109] = val2110; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2115 in this.success) { + if (this.success.hasOwnProperty(kiter2115)) { + let viter2116 = this.success[kiter2115]; + output.writeI64(kiter2115); + output.writeSetBegin(Thrift.Type.STRUCT, viter2116.length); + for (let iter2117 in viter2116) { + if (viter2116.hasOwnProperty(iter2117)) { + iter2117 = viter2116[iter2117]; + iter2117.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCclTimestr_args = class { + constructor(args) { + this.key = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCclTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32119 = input.readMapBegin(); + const _size2118 = _rtmp32119.size || 0; + for (let _i2120 = 0; _i2120 < _size2118; ++_i2120) { + let key2121 = null; + let val2122 = null; + key2121 = input.readI64(); + val2122 = []; + const _rtmp32124 = input.readSetBegin(); + const _size2123 = _rtmp32124.size || 0; + for (let _i2125 = 0; _i2125 < _size2123; ++_i2125) { + let elem2126 = null; + elem2126 = new data_ttypes.TObject(); + elem2126.read(input); + val2122.push(elem2126); + } + input.readSetEnd(); + this.success[key2121] = val2122; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2127 in this.success) { + if (this.success.hasOwnProperty(kiter2127)) { + let viter2128 = this.success[kiter2127]; + output.writeI64(kiter2127); + output.writeSetBegin(Thrift.Type.STRUCT, viter2128.length); + for (let iter2129 in viter2128) { + if (viter2128.hasOwnProperty(iter2129)) { + iter2129 = viter2128[iter2129]; + iter2129.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCcl_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32131 = input.readListBegin(); + const _size2130 = _rtmp32131.size || 0; + for (let _i2132 = 0; _i2132 < _size2130; ++_i2132) { + let elem2133 = null; + elem2133 = input.readString(); + this.keys.push(elem2133); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCcl_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2134 in this.keys) { + if (this.keys.hasOwnProperty(iter2134)) { + iter2134 = this.keys[iter2134]; + output.writeString(iter2134); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCcl_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32136 = input.readMapBegin(); + const _size2135 = _rtmp32136.size || 0; + for (let _i2137 = 0; _i2137 < _size2135; ++_i2137) { + let key2138 = null; + let val2139 = null; + key2138 = input.readI64(); + val2139 = {}; + const _rtmp32141 = input.readMapBegin(); + const _size2140 = _rtmp32141.size || 0; + for (let _i2142 = 0; _i2142 < _size2140; ++_i2142) { + let key2143 = null; + let val2144 = null; + key2143 = input.readString(); + val2144 = []; + const _rtmp32146 = input.readSetBegin(); + const _size2145 = _rtmp32146.size || 0; + for (let _i2147 = 0; _i2147 < _size2145; ++_i2147) { + let elem2148 = null; + elem2148 = new data_ttypes.TObject(); + elem2148.read(input); + val2144.push(elem2148); + } + input.readSetEnd(); + val2139[key2143] = val2144; + } + input.readMapEnd(); + this.success[key2138] = val2139; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCcl_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2149 in this.success) { + if (this.success.hasOwnProperty(kiter2149)) { + let viter2150 = this.success[kiter2149]; + output.writeI64(kiter2149); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2150)); + for (let kiter2151 in viter2150) { + if (viter2150.hasOwnProperty(kiter2151)) { + let viter2152 = viter2150[kiter2151]; + output.writeString(kiter2151); + output.writeSetBegin(Thrift.Type.STRUCT, viter2152.length); + for (let iter2153 in viter2152) { + if (viter2152.hasOwnProperty(iter2153)) { + iter2153 = viter2152[iter2153]; + iter2153.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCclTime_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32155 = input.readListBegin(); + const _size2154 = _rtmp32155.size || 0; + for (let _i2156 = 0; _i2156 < _size2154; ++_i2156) { + let elem2157 = null; + elem2157 = input.readString(); + this.keys.push(elem2157); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCclTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2158 in this.keys) { + if (this.keys.hasOwnProperty(iter2158)) { + iter2158 = this.keys[iter2158]; + output.writeString(iter2158); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCclTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32160 = input.readMapBegin(); + const _size2159 = _rtmp32160.size || 0; + for (let _i2161 = 0; _i2161 < _size2159; ++_i2161) { + let key2162 = null; + let val2163 = null; + key2162 = input.readI64(); + val2163 = {}; + const _rtmp32165 = input.readMapBegin(); + const _size2164 = _rtmp32165.size || 0; + for (let _i2166 = 0; _i2166 < _size2164; ++_i2166) { + let key2167 = null; + let val2168 = null; + key2167 = input.readString(); + val2168 = []; + const _rtmp32170 = input.readSetBegin(); + const _size2169 = _rtmp32170.size || 0; + for (let _i2171 = 0; _i2171 < _size2169; ++_i2171) { + let elem2172 = null; + elem2172 = new data_ttypes.TObject(); + elem2172.read(input); + val2168.push(elem2172); + } + input.readSetEnd(); + val2163[key2167] = val2168; + } + input.readMapEnd(); + this.success[key2162] = val2163; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCclTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2173 in this.success) { + if (this.success.hasOwnProperty(kiter2173)) { + let viter2174 = this.success[kiter2173]; + output.writeI64(kiter2173); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2174)); + for (let kiter2175 in viter2174) { + if (viter2174.hasOwnProperty(kiter2175)) { + let viter2176 = viter2174[kiter2175]; + output.writeString(kiter2175); + output.writeSetBegin(Thrift.Type.STRUCT, viter2176.length); + for (let iter2177 in viter2176) { + if (viter2176.hasOwnProperty(iter2177)) { + iter2177 = viter2176[iter2177]; + iter2177.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCclTimestr_args = class { + constructor(args) { + this.keys = null; + this.ccl = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.ccl !== undefined && args.ccl !== null) { + this.ccl = args.ccl; + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32179 = input.readListBegin(); + const _size2178 = _rtmp32179.size || 0; + for (let _i2180 = 0; _i2180 < _size2178; ++_i2180) { + let elem2181 = null; + elem2181 = input.readString(); + this.keys.push(elem2181); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.ccl = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCclTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2182 in this.keys) { + if (this.keys.hasOwnProperty(iter2182)) { + iter2182 = this.keys[iter2182]; + output.writeString(iter2182); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.ccl !== null && this.ccl !== undefined) { + output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); + output.writeString(this.ccl); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCclTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32184 = input.readMapBegin(); + const _size2183 = _rtmp32184.size || 0; + for (let _i2185 = 0; _i2185 < _size2183; ++_i2185) { + let key2186 = null; + let val2187 = null; + key2186 = input.readI64(); + val2187 = {}; + const _rtmp32189 = input.readMapBegin(); + const _size2188 = _rtmp32189.size || 0; + for (let _i2190 = 0; _i2190 < _size2188; ++_i2190) { + let key2191 = null; + let val2192 = null; + key2191 = input.readString(); + val2192 = []; + const _rtmp32194 = input.readSetBegin(); + const _size2193 = _rtmp32194.size || 0; + for (let _i2195 = 0; _i2195 < _size2193; ++_i2195) { + let elem2196 = null; + elem2196 = new data_ttypes.TObject(); + elem2196.read(input); + val2192.push(elem2196); + } + input.readSetEnd(); + val2187[key2191] = val2192; + } + input.readMapEnd(); + this.success[key2186] = val2187; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCclTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2197 in this.success) { + if (this.success.hasOwnProperty(kiter2197)) { + let viter2198 = this.success[kiter2197]; + output.writeI64(kiter2197); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2198)); + for (let kiter2199 in viter2198) { + if (viter2198.hasOwnProperty(kiter2199)) { + let viter2200 = viter2198[kiter2199]; + output.writeString(kiter2199); + output.writeSetBegin(Thrift.Type.STRUCT, viter2200.length); + for (let iter2201 in viter2200) { + if (viter2200.hasOwnProperty(iter2201)) { + iter2201 = viter2200[iter2201]; + iter2201.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCriteria_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteria_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32203 = input.readMapBegin(); + const _size2202 = _rtmp32203.size || 0; + for (let _i2204 = 0; _i2204 < _size2202; ++_i2204) { + let key2205 = null; + let val2206 = null; + key2205 = input.readI64(); + val2206 = []; + const _rtmp32208 = input.readSetBegin(); + const _size2207 = _rtmp32208.size || 0; + for (let _i2209 = 0; _i2209 < _size2207; ++_i2209) { + let elem2210 = null; + elem2210 = new data_ttypes.TObject(); + elem2210.read(input); + val2206.push(elem2210); + } + input.readSetEnd(); + this.success[key2205] = val2206; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2211 in this.success) { + if (this.success.hasOwnProperty(kiter2211)) { + let viter2212 = this.success[kiter2211]; + output.writeI64(kiter2211); + output.writeSetBegin(Thrift.Type.STRUCT, viter2212.length); + for (let iter2213 in viter2212) { + if (viter2212.hasOwnProperty(iter2213)) { + iter2213 = viter2212[iter2213]; + iter2213.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCriteriaTime_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteriaTime_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32215 = input.readMapBegin(); + const _size2214 = _rtmp32215.size || 0; + for (let _i2216 = 0; _i2216 < _size2214; ++_i2216) { + let key2217 = null; + let val2218 = null; + key2217 = input.readI64(); + val2218 = []; + const _rtmp32220 = input.readSetBegin(); + const _size2219 = _rtmp32220.size || 0; + for (let _i2221 = 0; _i2221 < _size2219; ++_i2221) { + let elem2222 = null; + elem2222 = new data_ttypes.TObject(); + elem2222.read(input); + val2218.push(elem2222); + } + input.readSetEnd(); + this.success[key2217] = val2218; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2223 in this.success) { + if (this.success.hasOwnProperty(kiter2223)) { + let viter2224 = this.success[kiter2223]; + output.writeI64(kiter2223); + output.writeSetBegin(Thrift.Type.STRUCT, viter2224.length); + for (let iter2225 in viter2224) { + if (viter2224.hasOwnProperty(iter2225)) { + iter2225 = viter2224[iter2225]; + iter2225.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCriteriaTimestr_args = class { + constructor(args) { + this.key = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.key !== undefined && args.key !== null) { + this.key = args.key; + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.key = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteriaTimestr_args'); + if (this.key !== null && this.key !== undefined) { + output.writeFieldBegin('key', Thrift.Type.STRING, 1); + output.writeString(this.key); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeyCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32227 = input.readMapBegin(); + const _size2226 = _rtmp32227.size || 0; + for (let _i2228 = 0; _i2228 < _size2226; ++_i2228) { + let key2229 = null; + let val2230 = null; + key2229 = input.readI64(); + val2230 = []; + const _rtmp32232 = input.readSetBegin(); + const _size2231 = _rtmp32232.size || 0; + for (let _i2233 = 0; _i2233 < _size2231; ++_i2233) { + let elem2234 = null; + elem2234 = new data_ttypes.TObject(); + elem2234.read(input); + val2230.push(elem2234); + } + input.readSetEnd(); + this.success[key2229] = val2230; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeyCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); + for (let kiter2235 in this.success) { + if (this.success.hasOwnProperty(kiter2235)) { + let viter2236 = this.success[kiter2235]; + output.writeI64(kiter2235); + output.writeSetBegin(Thrift.Type.STRUCT, viter2236.length); + for (let iter2237 in viter2236) { + if (viter2236.hasOwnProperty(iter2237)) { + iter2237 = viter2236[iter2237]; + iter2237.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCriteria_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32239 = input.readListBegin(); + const _size2238 = _rtmp32239.size || 0; + for (let _i2240 = 0; _i2240 < _size2238; ++_i2240) { + let elem2241 = null; + elem2241 = input.readString(); + this.keys.push(elem2241); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteria_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2242 in this.keys) { + if (this.keys.hasOwnProperty(iter2242)) { + iter2242 = this.keys[iter2242]; + output.writeString(iter2242); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 5); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCriteria_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32244 = input.readMapBegin(); + const _size2243 = _rtmp32244.size || 0; + for (let _i2245 = 0; _i2245 < _size2243; ++_i2245) { + let key2246 = null; + let val2247 = null; + key2246 = input.readI64(); + val2247 = {}; + const _rtmp32249 = input.readMapBegin(); + const _size2248 = _rtmp32249.size || 0; + for (let _i2250 = 0; _i2250 < _size2248; ++_i2250) { + let key2251 = null; + let val2252 = null; + key2251 = input.readString(); + val2252 = []; + const _rtmp32254 = input.readSetBegin(); + const _size2253 = _rtmp32254.size || 0; + for (let _i2255 = 0; _i2255 < _size2253; ++_i2255) { + let elem2256 = null; + elem2256 = new data_ttypes.TObject(); + elem2256.read(input); + val2252.push(elem2256); + } + input.readSetEnd(); + val2247[key2251] = val2252; + } + input.readMapEnd(); + this.success[key2246] = val2247; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteria_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2257 in this.success) { + if (this.success.hasOwnProperty(kiter2257)) { + let viter2258 = this.success[kiter2257]; + output.writeI64(kiter2257); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2258)); + for (let kiter2259 in viter2258) { + if (viter2258.hasOwnProperty(kiter2259)) { + let viter2260 = viter2258[kiter2259]; + output.writeString(kiter2259); + output.writeSetBegin(Thrift.Type.STRUCT, viter2260.length); + for (let iter2261 in viter2260) { + if (viter2260.hasOwnProperty(iter2261)) { + iter2261 = viter2260[iter2261]; + iter2261.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCriteriaTime_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32263 = input.readListBegin(); + const _size2262 = _rtmp32263.size || 0; + for (let _i2264 = 0; _i2264 < _size2262; ++_i2264) { + let elem2265 = null; + elem2265 = input.readString(); + this.keys.push(elem2265); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteriaTime_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2266 in this.keys) { + if (this.keys.hasOwnProperty(iter2266)) { + iter2266 = this.keys[iter2266]; + output.writeString(iter2266); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCriteriaTime_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32268 = input.readMapBegin(); + const _size2267 = _rtmp32268.size || 0; + for (let _i2269 = 0; _i2269 < _size2267; ++_i2269) { + let key2270 = null; + let val2271 = null; + key2270 = input.readI64(); + val2271 = {}; + const _rtmp32273 = input.readMapBegin(); + const _size2272 = _rtmp32273.size || 0; + for (let _i2274 = 0; _i2274 < _size2272; ++_i2274) { + let key2275 = null; + let val2276 = null; + key2275 = input.readString(); + val2276 = []; + const _rtmp32278 = input.readSetBegin(); + const _size2277 = _rtmp32278.size || 0; + for (let _i2279 = 0; _i2279 < _size2277; ++_i2279) { + let elem2280 = null; + elem2280 = new data_ttypes.TObject(); + elem2280.read(input); + val2276.push(elem2280); + } + input.readSetEnd(); + val2271[key2275] = val2276; + } + input.readMapEnd(); + this.success[key2270] = val2271; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteriaTime_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2281 in this.success) { + if (this.success.hasOwnProperty(kiter2281)) { + let viter2282 = this.success[kiter2281]; + output.writeI64(kiter2281); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2282)); + for (let kiter2283 in viter2282) { + if (viter2282.hasOwnProperty(kiter2283)) { + let viter2284 = viter2282[kiter2283]; + output.writeString(kiter2283); + output.writeSetBegin(Thrift.Type.STRUCT, viter2284.length); + for (let iter2285 in viter2284) { + if (viter2284.hasOwnProperty(iter2285)) { + iter2285 = viter2284[iter2285]; + iter2285.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCriteriaTimestr_args = class { + constructor(args) { + this.keys = null; + this.criteria = null; + this.timestamp = null; + this.creds = null; + this.transaction = null; + this.environment = null; + if (args) { + if (args.keys !== undefined && args.keys !== null) { + this.keys = Thrift.copyList(args.keys, [null]); + } + if (args.criteria !== undefined && args.criteria !== null) { + this.criteria = new data_ttypes.TCriteria(args.criteria); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.transaction !== undefined && args.transaction !== null) { + this.transaction = new shared_ttypes.TransactionToken(args.transaction); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.keys = []; + const _rtmp32287 = input.readListBegin(); + const _size2286 = _rtmp32287.size || 0; + for (let _i2288 = 0; _i2288 < _size2286; ++_i2288) { + let elem2289 = null; + elem2289 = input.readString(); + this.keys.push(elem2289); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.criteria = new data_ttypes.TCriteria(); + this.criteria.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.timestamp = input.readString(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.STRUCT) { + this.transaction = new shared_ttypes.TransactionToken(); + this.transaction.read(input); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteriaTimestr_args'); + if (this.keys !== null && this.keys !== undefined) { + output.writeFieldBegin('keys', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRING, this.keys.length); + for (let iter2290 in this.keys) { + if (this.keys.hasOwnProperty(iter2290)) { + iter2290 = this.keys[iter2290]; + output.writeString(iter2290); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.criteria !== null && this.criteria !== undefined) { + output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); + this.criteria.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); + output.writeString(this.timestamp); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.transaction !== null && this.transaction !== undefined) { + output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); + this.transaction.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 6); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_navigateKeysCriteriaTimestr_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.MAP) { + this.success = {}; + const _rtmp32292 = input.readMapBegin(); + const _size2291 = _rtmp32292.size || 0; + for (let _i2293 = 0; _i2293 < _size2291; ++_i2293) { + let key2294 = null; + let val2295 = null; + key2294 = input.readI64(); + val2295 = {}; + const _rtmp32297 = input.readMapBegin(); + const _size2296 = _rtmp32297.size || 0; + for (let _i2298 = 0; _i2298 < _size2296; ++_i2298) { + let key2299 = null; + let val2300 = null; + key2299 = input.readString(); + val2300 = []; + const _rtmp32302 = input.readSetBegin(); + const _size2301 = _rtmp32302.size || 0; + for (let _i2303 = 0; _i2303 < _size2301; ++_i2303) { + let elem2304 = null; + elem2304 = new data_ttypes.TObject(); + elem2304.read(input); + val2300.push(elem2304); + } + input.readSetEnd(); + val2295[key2299] = val2300; + } + input.readMapEnd(); + this.success[key2294] = val2295; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_navigateKeysCriteriaTimestr_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.MAP, 0); + output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); + for (let kiter2305 in this.success) { + if (this.success.hasOwnProperty(kiter2305)) { + let viter2306 = this.success[kiter2305]; + output.writeI64(kiter2305); + output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2306)); + for (let kiter2307 in viter2306) { + if (viter2306.hasOwnProperty(kiter2307)) { + let viter2308 = viter2306[kiter2307]; + output.writeString(kiter2307); + output.writeSetBegin(Thrift.Type.STRUCT, viter2308.length); + for (let iter2309 in viter2308) { + if (viter2308.hasOwnProperty(iter2309)) { + iter2309 = viter2308[iter2309]; + iter2309.write(output); + } + } + output.writeSetEnd(); + } + } + output.writeMapEnd(); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getServerEnvironment_args = class { + constructor(args) { + this.creds = null; + this.token = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.TransactionToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.token = new shared_ttypes.TransactionToken(); + this.token.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getServerEnvironment_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 2); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getServerEnvironment_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getServerEnvironment_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRING, 0); + output.writeString(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getServerVersion_args = class { + constructor(args) { + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + if (ftype == Thrift.Type.STOP) { + break; + } + input.skip(ftype); + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getServerVersion_args'); + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_getServerVersion_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRING) { + this.success = input.readString(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_getServerVersion_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRING, 0); + output.writeString(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_time_args = class { + constructor(args) { + this.creds = null; + this.token = null; + this.environment = null; + if (args) { + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.TransactionToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.token = new shared_ttypes.TransactionToken(); + this.token.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_time_args'); + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 2); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 3); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_time_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex3 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.PermissionException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_time_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_timePhrase_args = class { + constructor(args) { + this.phrase = null; + this.creds = null; + this.token = null; + this.environment = null; + if (args) { + if (args.phrase !== undefined && args.phrase !== null) { + this.phrase = args.phrase; + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + if (args.token !== undefined && args.token !== null) { + this.token = new shared_ttypes.TransactionToken(args.token); + } + if (args.environment !== undefined && args.environment !== null) { + this.environment = args.environment; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.phrase = input.readString(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.token = new shared_ttypes.TransactionToken(); + this.token.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRING) { + this.environment = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_timePhrase_args'); + if (this.phrase !== null && this.phrase !== undefined) { + output.writeFieldBegin('phrase', Thrift.Type.STRING, 1); + output.writeString(this.phrase); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); + this.creds.write(output); + output.writeFieldEnd(); + } + if (this.token !== null && this.token !== undefined) { + output.writeFieldBegin('token', Thrift.Type.STRUCT, 3); + this.token.write(output); + output.writeFieldEnd(); + } + if (this.environment !== null && this.environment !== undefined) { + output.writeFieldBegin('environment', Thrift.Type.STRING, 4); + output.writeString(this.environment); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_timePhrase_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + this.ex3 = null; + this.ex4 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.TransactionException) { + this.ex2 = args; + return; + } + if (args instanceof exceptions_ttypes.ParseException) { + this.ex3 = args; + return; + } + if (args instanceof exceptions_ttypes.PermissionException) { + this.ex4 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = args.success; + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + if (args.ex3 !== undefined && args.ex3 !== null) { + this.ex3 = args.ex3; + } + if (args.ex4 !== undefined && args.ex4 !== null) { + this.ex4 = args.ex4; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.I64) { + this.success = input.readI64(); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.TransactionException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.STRUCT) { + this.ex3 = new exceptions_ttypes.ParseException(); + this.ex3.read(input); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.ex4 = new exceptions_ttypes.PermissionException(); + this.ex4.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_timePhrase_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.I64, 0); + output.writeI64(this.success); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + if (this.ex3 !== null && this.ex3 !== undefined) { + output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); + this.ex3.write(output); + output.writeFieldEnd(); + } + if (this.ex4 !== null && this.ex4 !== undefined) { + output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); + this.ex4.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_invokeManagement_args = class { + constructor(args) { + this.method = null; + this.params = null; + this.creds = null; + if (args) { + if (args.method !== undefined && args.method !== null) { + this.method = args.method; + } + if (args.params !== undefined && args.params !== null) { + this.params = Thrift.copyList(args.params, [complex_ttypes.ComplexTObject]); + } + if (args.creds !== undefined && args.creds !== null) { + this.creds = new shared_ttypes.AccessToken(args.creds); + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 2: + if (ftype == Thrift.Type.STRING) { + this.method = input.readString(); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.LIST) { + this.params = []; + const _rtmp32311 = input.readListBegin(); + const _size2310 = _rtmp32311.size || 0; + for (let _i2312 = 0; _i2312 < _size2310; ++_i2312) { + let elem2313 = null; + elem2313 = new complex_ttypes.ComplexTObject(); + elem2313.read(input); + this.params.push(elem2313); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.STRUCT) { + this.creds = new shared_ttypes.AccessToken(); + this.creds.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_invokeManagement_args'); + if (this.method !== null && this.method !== undefined) { + output.writeFieldBegin('method', Thrift.Type.STRING, 2); + output.writeString(this.method); + output.writeFieldEnd(); + } + if (this.params !== null && this.params !== undefined) { + output.writeFieldBegin('params', Thrift.Type.LIST, 3); + output.writeListBegin(Thrift.Type.STRUCT, this.params.length); + for (let iter2314 in this.params) { + if (this.params.hasOwnProperty(iter2314)) { + iter2314 = this.params[iter2314]; + iter2314.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.creds !== null && this.creds !== undefined) { + output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); + this.creds.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseService_invokeManagement_result = class { + constructor(args) { + this.success = null; + this.ex = null; + this.ex2 = null; + if (args instanceof exceptions_ttypes.SecurityException) { + this.ex = args; + return; + } + if (args instanceof exceptions_ttypes.ManagementException) { + this.ex2 = args; + return; + } + if (args) { + if (args.success !== undefined && args.success !== null) { + this.success = new complex_ttypes.ComplexTObject(args.success); + } + if (args.ex !== undefined && args.ex !== null) { + this.ex = args.ex; + } + if (args.ex2 !== undefined && args.ex2 !== null) { + this.ex2 = args.ex2; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 0: + if (ftype == Thrift.Type.STRUCT) { + this.success = new complex_ttypes.ComplexTObject(); + this.success.read(input); + } else { + input.skip(ftype); + } + break; + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.ex = new exceptions_ttypes.SecurityException(); + this.ex.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.ex2 = new exceptions_ttypes.ManagementException(); + this.ex2.read(input); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ConcourseService_invokeManagement_result'); + if (this.success !== null && this.success !== undefined) { + output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); + this.success.write(output); + output.writeFieldEnd(); + } + if (this.ex !== null && this.ex !== undefined) { + output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); + this.ex.write(output); + output.writeFieldEnd(); + } + if (this.ex2 !== null && this.ex2 !== undefined) { + output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); + this.ex2.write(output); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ConcourseServiceClient = exports.Client = class { + constructor(output, pClass) { + this.output = output; + this.pClass = pClass; + this._seqid = 0; + this._reqs = {}; + } + seqid () { return this._seqid; } + new_seqid () { return this._seqid += 1; } + + abort (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_abort(creds, transaction, environment); + }); + } + + send_abort (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_abort_args(params); + try { + output.writeMessageBegin('abort', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_abort (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_abort_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + callback(null); + } + + addKeyValue (key, value, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_addKeyValue(key, value, creds, transaction, environment); + }); + } + + send_addKeyValue (key, value, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_addKeyValue_args(params); + try { + output.writeMessageBegin('addKeyValue', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_addKeyValue (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_addKeyValue_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('addKeyValue failed: unknown result'); + } + + addKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_addKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_addKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_addKeyValueRecord_args(params); + try { + output.writeMessageBegin('addKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_addKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_addKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('addKeyValueRecord failed: unknown result'); + } + + addKeyValueRecords (key, value, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_addKeyValueRecords(key, value, records, creds, transaction, environment); + }); + } + + send_addKeyValueRecords (key, value, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_addKeyValueRecords_args(params); + try { + output.writeMessageBegin('addKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_addKeyValueRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_addKeyValueRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('addKeyValueRecords failed: unknown result'); + } + + auditRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecord(record, creds, transaction, environment); + }); + } + + send_auditRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecord_args(params); + try { + output.writeMessageBegin('auditRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecord failed: unknown result'); + } + + auditRecordStart (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStart(record, start, creds, transaction, environment); + }); + } + + send_auditRecordStart (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStart_args(params); + try { + output.writeMessageBegin('auditRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStart failed: unknown result'); + } + + auditRecordStartstr (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStartstr(record, start, creds, transaction, environment); + }); + } + + send_auditRecordStartstr (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStartstr_args(params); + try { + output.writeMessageBegin('auditRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStartstr failed: unknown result'); + } + + auditRecordStartEnd (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStartEnd(record, start, tend, creds, transaction, environment); + }); + } + + send_auditRecordStartEnd (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStartEnd_args(params); + try { + output.writeMessageBegin('auditRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStartEnd failed: unknown result'); + } + + auditRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditRecordStartstrEndstr(record, start, tend, creds, transaction, environment); + }); + } + + send_auditRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('auditRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditRecordStartstrEndstr failed: unknown result'); + } + + auditKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_auditKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecord_args(params); + try { + output.writeMessageBegin('auditKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecord failed: unknown result'); + } + + auditKeyRecordStart (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStart(key, record, start, creds, transaction, environment); + }); + } + + send_auditKeyRecordStart (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStart_args(params); + try { + output.writeMessageBegin('auditKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStart failed: unknown result'); + } + + auditKeyRecordStartstr (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStartstr(key, record, start, creds, transaction, environment); + }); + } + + send_auditKeyRecordStartstr (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStartstr_args(params); + try { + output.writeMessageBegin('auditKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStartstr failed: unknown result'); + } + + auditKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); + }); + } + + send_auditKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStartEnd_args(params); + try { + output.writeMessageBegin('auditKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStartEnd failed: unknown result'); + } + + auditKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_auditKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); + }); + } + + send_auditKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_auditKeyRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('auditKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_auditKeyRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_auditKeyRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('auditKeyRecordStartstrEndstr failed: unknown result'); + } + + browseKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKey(key, creds, transaction, environment); + }); + } + + send_browseKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKey_args(params); + try { + output.writeMessageBegin('browseKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKey failed: unknown result'); + } + + browseKeys (keys, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeys(keys, creds, transaction, environment); + }); + } + + send_browseKeys (keys, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeys_args(params); + try { + output.writeMessageBegin('browseKeys', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeys (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeys_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeys failed: unknown result'); + } + + browseKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_browseKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeyTime_args(params); + try { + output.writeMessageBegin('browseKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeyTime failed: unknown result'); + } + + browseKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_browseKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeyTimestr_args(params); + try { + output.writeMessageBegin('browseKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeyTimestr failed: unknown result'); + } + + browseKeysTime (keys, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeysTime(keys, timestamp, creds, transaction, environment); + }); + } + + send_browseKeysTime (keys, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeysTime_args(params); + try { + output.writeMessageBegin('browseKeysTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeysTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeysTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeysTime failed: unknown result'); + } + + browseKeysTimestr (keys, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_browseKeysTimestr(keys, timestamp, creds, transaction, environment); + }); + } + + send_browseKeysTimestr (keys, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_browseKeysTimestr_args(params); + try { + output.writeMessageBegin('browseKeysTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_browseKeysTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_browseKeysTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('browseKeysTimestr failed: unknown result'); + } + + chronologizeKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecord_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecord failed: unknown result'); + } + + chronologizeKeyRecordStart (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStart(key, record, start, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStart (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStart_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStart failed: unknown result'); + } + + chronologizeKeyRecordStartstr (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStartstr(key, record, start, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStartstr (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStartstr_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStartstr failed: unknown result'); + } + + chronologizeKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStartEnd_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStartEnd failed: unknown result'); + } + + chronologizeKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_chronologizeKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); + }); + } + + send_chronologizeKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_chronologizeKeyRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('chronologizeKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_chronologizeKeyRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('chronologizeKeyRecordStartstrEndstr failed: unknown result'); + } + + clearRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearRecord(record, creds, transaction, environment); + }); + } + + send_clearRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearRecord_args(params); + try { + output.writeMessageBegin('clearRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearRecords(records, creds, transaction, environment); + }); + } + + send_clearRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearRecords_args(params); + try { + output.writeMessageBegin('clearRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_clearKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeyRecord_args(params); + try { + output.writeMessageBegin('clearKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_clearKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeysRecord_args(params); + try { + output.writeMessageBegin('clearKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_clearKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeyRecords_args(params); + try { + output.writeMessageBegin('clearKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + clearKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_clearKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_clearKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_clearKeysRecords_args(params); + try { + output.writeMessageBegin('clearKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_clearKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_clearKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + commit (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_commit(creds, transaction, environment); + }); + } + + send_commit (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_commit_args(params); + try { + output.writeMessageBegin('commit', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_commit (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_commit_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('commit failed: unknown result'); + } + + describe (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describe(creds, transaction, environment); + }); + } + + send_describe (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describe_args(params); + try { + output.writeMessageBegin('describe', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describe (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describe_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describe failed: unknown result'); + } + + describeTime (timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeTime(timestamp, creds, transaction, environment); + }); + } + + send_describeTime (timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeTime_args(params); + try { + output.writeMessageBegin('describeTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeTime failed: unknown result'); + } + + describeTimestr (timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeTimestr(timestamp, creds, transaction, environment); + }); + } + + send_describeTimestr (timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeTimestr_args(params); + try { + output.writeMessageBegin('describeTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeTimestr failed: unknown result'); + } + + describeRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecord(record, creds, transaction, environment); + }); + } + + send_describeRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecord_args(params); + try { + output.writeMessageBegin('describeRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecord failed: unknown result'); + } + + describeRecordTime (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordTime(record, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordTime (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordTime_args(params); + try { + output.writeMessageBegin('describeRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordTime failed: unknown result'); + } + + describeRecordTimestr (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordTimestr(record, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordTimestr (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordTimestr_args(params); + try { + output.writeMessageBegin('describeRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordTimestr failed: unknown result'); + } + + describeRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecords(records, creds, transaction, environment); + }); + } + + send_describeRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecords_args(params); + try { + output.writeMessageBegin('describeRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecords failed: unknown result'); + } + + describeRecordsTime (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordsTime(records, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordsTime (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordsTime_args(params); + try { + output.writeMessageBegin('describeRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordsTime failed: unknown result'); + } + + describeRecordsTimestr (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_describeRecordsTimestr(records, timestamp, creds, transaction, environment); + }); + } + + send_describeRecordsTimestr (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_describeRecordsTimestr_args(params); + try { + output.writeMessageBegin('describeRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_describeRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_describeRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('describeRecordsTimestr failed: unknown result'); + } + + diffRecordStart (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStart(record, start, creds, transaction, environment); + }); + } + + send_diffRecordStart (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStart_args(params); + try { + output.writeMessageBegin('diffRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStart failed: unknown result'); + } + + diffRecordStartstr (record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStartstr(record, start, creds, transaction, environment); + }); + } + + send_diffRecordStartstr (record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStartstr_args(params); + try { + output.writeMessageBegin('diffRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStartstr failed: unknown result'); + } + + diffRecordStartEnd (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStartEnd(record, start, tend, creds, transaction, environment); + }); + } + + send_diffRecordStartEnd (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStartEnd_args(params); + try { + output.writeMessageBegin('diffRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStartEnd failed: unknown result'); + } + + diffRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffRecordStartstrEndstr(record, start, tend, creds, transaction, environment); + }); + } + + send_diffRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('diffRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffRecordStartstrEndstr failed: unknown result'); + } + + diffKeyRecordStart (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStart(key, record, start, creds, transaction, environment); + }); + } + + send_diffKeyRecordStart (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStart_args(params); + try { + output.writeMessageBegin('diffKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStart failed: unknown result'); + } + + diffKeyRecordStartstr (key, record, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStartstr(key, record, start, creds, transaction, environment); + }); + } + + send_diffKeyRecordStartstr (key, record, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStartstr_args(params); + try { + output.writeMessageBegin('diffKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStartstr failed: unknown result'); + } + + diffKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStartEnd_args(params); + try { + output.writeMessageBegin('diffKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStartEnd failed: unknown result'); + } + + diffKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyRecordStartstrEndstr_args(params); + try { + output.writeMessageBegin('diffKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyRecordStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyRecordStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyRecordStartstrEndstr failed: unknown result'); + } + + diffKeyStart (key, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStart(key, start, creds, transaction, environment); + }); + } + + send_diffKeyStart (key, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStart_args(params); + try { + output.writeMessageBegin('diffKeyStart', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStart (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStart_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStart failed: unknown result'); + } + + diffKeyStartstr (key, start, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStartstr(key, start, creds, transaction, environment); + }); + } + + send_diffKeyStartstr (key, start, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStartstr_args(params); + try { + output.writeMessageBegin('diffKeyStartstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStartstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStartstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStartstr failed: unknown result'); + } + + diffKeyStartEnd (key, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStartEnd(key, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyStartEnd (key, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStartEnd_args(params); + try { + output.writeMessageBegin('diffKeyStartEnd', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStartEnd (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStartEnd_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStartEnd failed: unknown result'); + } + + diffKeyStartstrEndstr (key, start, tend, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_diffKeyStartstrEndstr(key, start, tend, creds, transaction, environment); + }); + } + + send_diffKeyStartstrEndstr (key, start, tend, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + start: start, + tend: tend, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_diffKeyStartstrEndstr_args(params); + try { + output.writeMessageBegin('diffKeyStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_diffKeyStartstrEndstr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_diffKeyStartstrEndstr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('diffKeyStartstrEndstr failed: unknown result'); + } + + invokePlugin (id, method, params, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_invokePlugin(id, method, params, creds, transaction, environment); + }); + } + + send_invokePlugin (id, method, params, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + id: id, + method: method, + params: params, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_invokePlugin_args(params); + try { + output.writeMessageBegin('invokePlugin', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_invokePlugin (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_invokePlugin_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('invokePlugin failed: unknown result'); + } + + login (username, password, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_login(username, password, environment); + }); + } + + send_login (username, password, environment) { + const output = new this.pClass(this.output); + const params = { + username: username, + password: password, + environment: environment + }; + const args = new ConcourseService_login_args(params); + try { + output.writeMessageBegin('login', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_login (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_login_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('login failed: unknown result'); + } + + logout (token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_logout(token, environment); + }); + } + + send_logout (token, environment) { + const output = new this.pClass(this.output); + const params = { + token: token, + environment: environment + }; + const args = new ConcourseService_logout_args(params); + try { + output.writeMessageBegin('logout', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_logout (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_logout_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + callback(null); + } + + stage (token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_stage(token, environment); + }); + } + + send_stage (token, environment) { + const output = new this.pClass(this.output); + const params = { + token: token, + environment: environment + }; + const args = new ConcourseService_stage_args(params); + try { + output.writeMessageBegin('stage', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_stage (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_stage_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('stage failed: unknown result'); + } + + insertJson (json, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_insertJson(json, creds, transaction, environment); + }); + } + + send_insertJson (json, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + json: json, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_insertJson_args(params); + try { + output.writeMessageBegin('insertJson', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_insertJson (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_insertJson_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('insertJson failed: unknown result'); + } + + insertJsonRecord (json, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_insertJsonRecord(json, record, creds, transaction, environment); + }); + } + + send_insertJsonRecord (json, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + json: json, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_insertJsonRecord_args(params); + try { + output.writeMessageBegin('insertJsonRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_insertJsonRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_insertJsonRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('insertJsonRecord failed: unknown result'); + } + + insertJsonRecords (json, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_insertJsonRecords(json, records, creds, transaction, environment); + }); + } + + send_insertJsonRecords (json, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + json: json, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_insertJsonRecords_args(params); + try { + output.writeMessageBegin('insertJsonRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_insertJsonRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_insertJsonRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('insertJsonRecords failed: unknown result'); + } + + removeKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_removeKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_removeKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_removeKeyValueRecord_args(params); + try { + output.writeMessageBegin('removeKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_removeKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_removeKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('removeKeyValueRecord failed: unknown result'); + } + + removeKeyValueRecords (key, value, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_removeKeyValueRecords(key, value, records, creds, transaction, environment); + }); + } + + send_removeKeyValueRecords (key, value, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_removeKeyValueRecords_args(params); + try { + output.writeMessageBegin('removeKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_removeKeyValueRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_removeKeyValueRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('removeKeyValueRecords failed: unknown result'); + } + + setKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_setKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_setKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_setKeyValueRecord_args(params); + try { + output.writeMessageBegin('setKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_setKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_setKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + setKeyValue (key, value, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_setKeyValue(key, value, creds, transaction, environment); + }); + } + + send_setKeyValue (key, value, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_setKeyValue_args(params); + try { + output.writeMessageBegin('setKeyValue', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_setKeyValue (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_setKeyValue_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('setKeyValue failed: unknown result'); + } + + setKeyValueRecords (key, value, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_setKeyValueRecords(key, value, records, creds, transaction, environment); + }); + } + + send_setKeyValueRecords (key, value, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_setKeyValueRecords_args(params); + try { + output.writeMessageBegin('setKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_setKeyValueRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_setKeyValueRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + reconcileKeyRecordValues (key, record, values, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_reconcileKeyRecordValues(key, record, values, creds, transaction, environment); + }); + } + + send_reconcileKeyRecordValues (key, record, values, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + values: values, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_reconcileKeyRecordValues_args(params); + try { + output.writeMessageBegin('reconcileKeyRecordValues', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_reconcileKeyRecordValues (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_reconcileKeyRecordValues_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + inventory (creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_inventory(creds, transaction, environment); + }); + } + + send_inventory (creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_inventory_args(params); + try { + output.writeMessageBegin('inventory', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_inventory (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_inventory_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('inventory failed: unknown result'); + } + + selectRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecord(record, creds, transaction, environment); + }); + } + + send_selectRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecord_args(params); + try { + output.writeMessageBegin('selectRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecord failed: unknown result'); + } + + selectRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecords(records, creds, transaction, environment); + }); + } + + send_selectRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecords_args(params); + try { + output.writeMessageBegin('selectRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecords failed: unknown result'); + } + + selectRecordTime (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordTime(record, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordTime (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordTime_args(params); + try { + output.writeMessageBegin('selectRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordTime failed: unknown result'); + } + + selectRecordTimestr (record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordTimestr(record, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordTimestr (record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordTimestr_args(params); + try { + output.writeMessageBegin('selectRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordTimestr failed: unknown result'); + } + + selectRecordsTime (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordsTime(records, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordsTime (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordsTime_args(params); + try { + output.writeMessageBegin('selectRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordsTime failed: unknown result'); + } + + selectRecordsTimestr (records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectRecordsTimestr(records, timestamp, creds, transaction, environment); + }); + } + + send_selectRecordsTimestr (records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectRecordsTimestr_args(params); + try { + output.writeMessageBegin('selectRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectRecordsTimestr failed: unknown result'); + } + + selectKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_selectKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecord_args(params); + try { + output.writeMessageBegin('selectKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecord failed: unknown result'); + } + + selectKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordTime_args(params); + try { + output.writeMessageBegin('selectKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordTime failed: unknown result'); + } + + selectKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('selectKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordTimestr failed: unknown result'); + } + + selectKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_selectKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecord_args(params); + try { + output.writeMessageBegin('selectKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecord failed: unknown result'); + } + + selectKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordTime_args(params); + try { + output.writeMessageBegin('selectKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordTime failed: unknown result'); + } + + selectKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('selectKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordTimestr failed: unknown result'); + } + + selectKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_selectKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecords_args(params); + try { + output.writeMessageBegin('selectKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecords failed: unknown result'); + } + + selectKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_selectKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecords_args(params); + try { + output.writeMessageBegin('selectKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecords failed: unknown result'); + } + + selectKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordsTime_args(params); + try { + output.writeMessageBegin('selectKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordsTime failed: unknown result'); + } + + selectKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('selectKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyRecordsTimestr failed: unknown result'); + } + + selectKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordsTime_args(params); + try { + output.writeMessageBegin('selectKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordsTime failed: unknown result'); + } + + selectKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('selectKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysRecordsTimestr failed: unknown result'); + } + + selectCriteria (criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCriteria(criteria, creds, transaction, environment); + }); + } + + send_selectCriteria (criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCriteria_args(params); + try { + output.writeMessageBegin('selectCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCriteria failed: unknown result'); + } + + selectCcl (ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCcl(ccl, creds, transaction, environment); + }); + } + + send_selectCcl (ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCcl_args(params); + try { + output.writeMessageBegin('selectCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCcl failed: unknown result'); + } + + selectCriteriaTime (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCriteriaTime(criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectCriteriaTime (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCriteriaTime_args(params); + try { + output.writeMessageBegin('selectCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCriteriaTime failed: unknown result'); + } + + selectCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCriteriaTimestr(criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCriteriaTimestr_args(params); + try { + output.writeMessageBegin('selectCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCriteriaTimestr failed: unknown result'); + } + + selectCclTime (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCclTime(ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectCclTime (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCclTime_args(params); + try { + output.writeMessageBegin('selectCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCclTime failed: unknown result'); + } + + selectCclTimestr (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectCclTimestr(ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectCclTimestr (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectCclTimestr_args(params); + try { + output.writeMessageBegin('selectCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectCclTimestr failed: unknown result'); + } + + selectKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_selectKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCriteria_args(params); + try { + output.writeMessageBegin('selectKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCriteria failed: unknown result'); + } + + selectKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_selectKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCcl_args(params); + try { + output.writeMessageBegin('selectKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCcl failed: unknown result'); + } + + selectKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('selectKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCriteriaTime failed: unknown result'); + } + + selectKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('selectKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCriteriaTimestr failed: unknown result'); + } + + selectKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCclTime_args(params); + try { + output.writeMessageBegin('selectKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCclTime failed: unknown result'); + } + + selectKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeyCclTimestr_args(params); + try { + output.writeMessageBegin('selectKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeyCclTimestr failed: unknown result'); + } + + selectKeysCriteria (keys, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCriteria(keys, criteria, creds, transaction, environment); + }); + } + + send_selectKeysCriteria (keys, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCriteria_args(params); + try { + output.writeMessageBegin('selectKeysCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCriteria failed: unknown result'); + } + + selectKeysCcl (keys, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCcl(keys, ccl, creds, transaction, environment); + }); + } + + send_selectKeysCcl (keys, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCcl_args(params); + try { + output.writeMessageBegin('selectKeysCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCcl failed: unknown result'); + } + + selectKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCriteriaTime_args(params); + try { + output.writeMessageBegin('selectKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCriteriaTime failed: unknown result'); + } + + selectKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCriteriaTimestr_args(params); + try { + output.writeMessageBegin('selectKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCriteriaTimestr failed: unknown result'); + } + + selectKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCclTime_args(params); + try { + output.writeMessageBegin('selectKeysCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCclTime failed: unknown result'); + } + + selectKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_selectKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_selectKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_selectKeysCclTimestr_args(params); + try { + output.writeMessageBegin('selectKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_selectKeysCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_selectKeysCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('selectKeysCclTimestr failed: unknown result'); + } + + getKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_getKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecord_args(params); + try { + output.writeMessageBegin('getKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecord failed: unknown result'); + } + + getKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordTime_args(params); + try { + output.writeMessageBegin('getKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordTime failed: unknown result'); + } + + getKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('getKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordTimestr failed: unknown result'); + } + + getKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_getKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecord_args(params); + try { + output.writeMessageBegin('getKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecord failed: unknown result'); + } + + getKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordTime_args(params); + try { + output.writeMessageBegin('getKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordTime failed: unknown result'); + } + + getKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('getKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordTimestr failed: unknown result'); + } + + getKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_getKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecords_args(params); + try { + output.writeMessageBegin('getKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecords failed: unknown result'); + } + + getKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_getKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecords_args(params); + try { + output.writeMessageBegin('getKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecords failed: unknown result'); + } + + getKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordsTime_args(params); + try { + output.writeMessageBegin('getKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordsTime failed: unknown result'); + } + + getKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('getKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyRecordsTimestr failed: unknown result'); + } + + getKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordsTime_args(params); + try { + output.writeMessageBegin('getKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordsTime failed: unknown result'); + } + + getKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_getKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('getKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysRecordsTimestr failed: unknown result'); + } + + getKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_getKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCriteria_args(params); + try { + output.writeMessageBegin('getKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCriteria failed: unknown result'); + } + + getCriteria (criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCriteria(criteria, creds, transaction, environment); + }); + } + + send_getCriteria (criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCriteria_args(params); + try { + output.writeMessageBegin('getCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCriteria failed: unknown result'); + } + + getCcl (ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCcl(ccl, creds, transaction, environment); + }); + } + + send_getCcl (ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCcl_args(params); + try { + output.writeMessageBegin('getCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCcl failed: unknown result'); + } + + getCriteriaTime (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCriteriaTime(criteria, timestamp, creds, transaction, environment); + }); + } + + send_getCriteriaTime (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCriteriaTime_args(params); + try { + output.writeMessageBegin('getCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCriteriaTime failed: unknown result'); + } + + getCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCriteriaTimestr(criteria, timestamp, creds, transaction, environment); + }); + } + + send_getCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCriteriaTimestr_args(params); + try { + output.writeMessageBegin('getCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCriteriaTimestr failed: unknown result'); + } + + getCclTime (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCclTime(ccl, timestamp, creds, transaction, environment); + }); + } + + send_getCclTime (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCclTime_args(params); + try { + output.writeMessageBegin('getCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCclTime failed: unknown result'); + } + + getCclTimestr (ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getCclTimestr(ccl, timestamp, creds, transaction, environment); + }); + } + + send_getCclTimestr (ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getCclTimestr_args(params); + try { + output.writeMessageBegin('getCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getCclTimestr failed: unknown result'); + } + + getKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_getKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCcl_args(params); + try { + output.writeMessageBegin('getKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCcl failed: unknown result'); + } + + getKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('getKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCriteriaTime failed: unknown result'); + } + + getKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('getKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCriteriaTimestr failed: unknown result'); + } + + getKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCclTime_args(params); + try { + output.writeMessageBegin('getKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCclTime failed: unknown result'); + } + + getKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeyCclTimestr_args(params); + try { + output.writeMessageBegin('getKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeyCclTimestr failed: unknown result'); + } + + getKeysCriteria (keys, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCriteria(keys, criteria, creds, transaction, environment); + }); + } + + send_getKeysCriteria (keys, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCriteria_args(params); + try { + output.writeMessageBegin('getKeysCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCriteria failed: unknown result'); + } + + getKeysCcl (keys, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCcl(keys, ccl, creds, transaction, environment); + }); + } + + send_getKeysCcl (keys, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCcl_args(params); + try { + output.writeMessageBegin('getKeysCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCcl failed: unknown result'); + } + + getKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCriteriaTime_args(params); + try { + output.writeMessageBegin('getKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCriteriaTime failed: unknown result'); + } + + getKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCriteriaTimestr_args(params); + try { + output.writeMessageBegin('getKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCriteriaTimestr failed: unknown result'); + } + + getKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCclTime_args(params); + try { + output.writeMessageBegin('getKeysCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCclTime failed: unknown result'); + } + + getKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_getKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_getKeysCclTimestr_args(params); + try { + output.writeMessageBegin('getKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getKeysCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getKeysCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getKeysCclTimestr failed: unknown result'); + } + + verifyKeyValueRecord (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyKeyValueRecord(key, value, record, creds, transaction, environment); + }); + } + + send_verifyKeyValueRecord (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyKeyValueRecord_args(params); + try { + output.writeMessageBegin('verifyKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyKeyValueRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyKeyValueRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyKeyValueRecord failed: unknown result'); + } + + verifyKeyValueRecordTime (key, value, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyKeyValueRecordTime(key, value, record, timestamp, creds, transaction, environment); + }); + } + + send_verifyKeyValueRecordTime (key, value, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyKeyValueRecordTime_args(params); + try { + output.writeMessageBegin('verifyKeyValueRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyKeyValueRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyKeyValueRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyKeyValueRecordTime failed: unknown result'); + } + + verifyKeyValueRecordTimestr (key, value, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyKeyValueRecordTimestr(key, value, record, timestamp, creds, transaction, environment); + }); + } + + send_verifyKeyValueRecordTimestr (key, value, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyKeyValueRecordTimestr_args(params); + try { + output.writeMessageBegin('verifyKeyValueRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyKeyValueRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyKeyValueRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyKeyValueRecordTimestr failed: unknown result'); + } + + jsonifyRecords (records, identifier, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_jsonifyRecords(records, identifier, creds, transaction, environment); + }); + } + + send_jsonifyRecords (records, identifier, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + identifier: identifier, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_jsonifyRecords_args(params); + try { + output.writeMessageBegin('jsonifyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_jsonifyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_jsonifyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('jsonifyRecords failed: unknown result'); + } + + jsonifyRecordsTime (records, timestamp, identifier, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_jsonifyRecordsTime(records, timestamp, identifier, creds, transaction, environment); + }); + } + + send_jsonifyRecordsTime (records, timestamp, identifier, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + identifier: identifier, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_jsonifyRecordsTime_args(params); + try { + output.writeMessageBegin('jsonifyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_jsonifyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_jsonifyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('jsonifyRecordsTime failed: unknown result'); + } + + jsonifyRecordsTimestr (records, timestamp, identifier, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_jsonifyRecordsTimestr(records, timestamp, identifier, creds, transaction, environment); + }); + } + + send_jsonifyRecordsTimestr (records, timestamp, identifier, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + timestamp: timestamp, + identifier: identifier, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_jsonifyRecordsTimestr_args(params); + try { + output.writeMessageBegin('jsonifyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_jsonifyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_jsonifyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('jsonifyRecordsTimestr failed: unknown result'); + } + + findCriteria (criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findCriteria(criteria, creds, transaction, environment); + }); + } + + send_findCriteria (criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findCriteria_args(params); + try { + output.writeMessageBegin('findCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findCriteria failed: unknown result'); + } + + findCcl (ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findCcl(ccl, creds, transaction, environment); + }); + } + + send_findCcl (ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findCcl_args(params); + try { + output.writeMessageBegin('findCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findCcl failed: unknown result'); + } + + findKeyOperatorValues (key, operator, values, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorValues(key, operator, values, creds, transaction, environment); + }); + } + + send_findKeyOperatorValues (key, operator, values, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorValues_args(params); + try { + output.writeMessageBegin('findKeyOperatorValues', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorValues (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorValues_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorValues failed: unknown result'); + } + + findKeyOperatorValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorValuesTime(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorValuesTime_args(params); + try { + output.writeMessageBegin('findKeyOperatorValuesTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorValuesTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorValuesTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorValuesTime failed: unknown result'); + } + + findKeyOperatorValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorValuesTimestr(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorValuesTimestr_args(params); + try { + output.writeMessageBegin('findKeyOperatorValuesTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorValuesTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorValuesTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorValuesTimestr failed: unknown result'); + } + + findKeyOperatorstrValues (key, operator, values, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorstrValues(key, operator, values, creds, transaction, environment); + }); + } + + send_findKeyOperatorstrValues (key, operator, values, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorstrValues_args(params); + try { + output.writeMessageBegin('findKeyOperatorstrValues', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorstrValues (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorstrValues_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorstrValues failed: unknown result'); + } + + findKeyOperatorstrValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorstrValuesTime(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorstrValuesTime (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorstrValuesTime_args(params); + try { + output.writeMessageBegin('findKeyOperatorstrValuesTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorstrValuesTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorstrValuesTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorstrValuesTime failed: unknown result'); + } + + findKeyOperatorstrValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findKeyOperatorstrValuesTimestr(key, operator, values, timestamp, creds, transaction, environment); + }); + } + + send_findKeyOperatorstrValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + operator: operator, + values: values, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findKeyOperatorstrValuesTimestr_args(params); + try { + output.writeMessageBegin('findKeyOperatorstrValuesTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findKeyOperatorstrValuesTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findKeyOperatorstrValuesTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findKeyOperatorstrValuesTimestr failed: unknown result'); + } + + search (key, query, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_search(key, query, creds, transaction, environment); + }); + } + + send_search (key, query, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + query: query, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_search_args(params); + try { + output.writeMessageBegin('search', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_search (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_search_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('search failed: unknown result'); + } + + revertKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordsTime_args(params); + try { + output.writeMessageBegin('revertKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('revertKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + revertKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordTime_args(params); + try { + output.writeMessageBegin('revertKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('revertKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + revertKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordsTime_args(params); + try { + output.writeMessageBegin('revertKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('revertKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + revertKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordTime_args(params); + try { + output.writeMessageBegin('revertKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + callback(null); + } + + revertKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_revertKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_revertKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_revertKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('revertKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_revertKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_revertKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + pingRecords (records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_pingRecords(records, creds, transaction, environment); + }); + } + + send_pingRecords (records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_pingRecords_args(params); + try { + output.writeMessageBegin('pingRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_pingRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_pingRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('pingRecords failed: unknown result'); + } + + pingRecord (record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_pingRecord(record, creds, transaction, environment); + }); + } + + send_pingRecord (record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_pingRecord_args(params); + try { + output.writeMessageBegin('pingRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_pingRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_pingRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('pingRecord failed: unknown result'); + } + + verifyAndSwap (key, expected, record, replacement, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyAndSwap(key, expected, record, replacement, creds, transaction, environment); + }); + } + + send_verifyAndSwap (key, expected, record, replacement, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + expected: expected, + record: record, + replacement: replacement, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyAndSwap_args(params); + try { + output.writeMessageBegin('verifyAndSwap', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyAndSwap (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyAndSwap_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('verifyAndSwap failed: unknown result'); + } + + verifyOrSet (key, value, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_verifyOrSet(key, value, record, creds, transaction, environment); + }); + } + + send_verifyOrSet (key, value, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_verifyOrSet_args(params); + try { + output.writeMessageBegin('verifyOrSet', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_verifyOrSet (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_verifyOrSet_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + callback(null); + } + + findOrAddKeyValue (key, value, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findOrAddKeyValue(key, value, creds, transaction, environment); + }); + } + + send_findOrAddKeyValue (key, value, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + value: value, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findOrAddKeyValue_args(params); + try { + output.writeMessageBegin('findOrAddKeyValue', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findOrAddKeyValue (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findOrAddKeyValue_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findOrAddKeyValue failed: unknown result'); + } + + findOrInsertCriteriaJson (criteria, json, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findOrInsertCriteriaJson(criteria, json, creds, transaction, environment); + }); + } + + send_findOrInsertCriteriaJson (criteria, json, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + criteria: criteria, + json: json, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findOrInsertCriteriaJson_args(params); + try { + output.writeMessageBegin('findOrInsertCriteriaJson', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findOrInsertCriteriaJson (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findOrInsertCriteriaJson_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findOrInsertCriteriaJson failed: unknown result'); + } + + findOrInsertCclJson (ccl, json, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_findOrInsertCclJson(ccl, json, creds, transaction, environment); + }); + } + + send_findOrInsertCclJson (ccl, json, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + ccl: ccl, + json: json, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_findOrInsertCclJson_args(params); + try { + output.writeMessageBegin('findOrInsertCclJson', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_findOrInsertCclJson (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_findOrInsertCclJson_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.ex5) { + return callback(result.ex5); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('findOrInsertCclJson failed: unknown result'); + } + + sumKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_sumKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecord_args(params); + try { + output.writeMessageBegin('sumKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecord failed: unknown result'); + } + + sumKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordTime_args(params); + try { + output.writeMessageBegin('sumKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordTime failed: unknown result'); + } + + sumKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('sumKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordTimestr failed: unknown result'); + } + + sumKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_sumKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecords_args(params); + try { + output.writeMessageBegin('sumKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecords failed: unknown result'); + } + + sumKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordsTime_args(params); + try { + output.writeMessageBegin('sumKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordsTime failed: unknown result'); + } + + sumKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('sumKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyRecordsTimestr failed: unknown result'); + } + + sumKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKey(key, creds, transaction, environment); + }); + } + + send_sumKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKey_args(params); + try { + output.writeMessageBegin('sumKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKey failed: unknown result'); + } + + sumKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyTime_args(params); + try { + output.writeMessageBegin('sumKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyTime failed: unknown result'); + } + + sumKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyTimestr_args(params); + try { + output.writeMessageBegin('sumKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyTimestr failed: unknown result'); + } + + sumKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_sumKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCriteria_args(params); + try { + output.writeMessageBegin('sumKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCriteria failed: unknown result'); + } + + sumKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('sumKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCriteriaTime failed: unknown result'); + } + + sumKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('sumKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCriteriaTimestr failed: unknown result'); + } + + sumKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_sumKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCcl_args(params); + try { + output.writeMessageBegin('sumKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCcl failed: unknown result'); + } + + sumKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCclTime_args(params); + try { + output.writeMessageBegin('sumKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCclTime failed: unknown result'); + } + + sumKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_sumKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_sumKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_sumKeyCclTimestr_args(params); + try { + output.writeMessageBegin('sumKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_sumKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_sumKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('sumKeyCclTimestr failed: unknown result'); + } + + averageKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_averageKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecord_args(params); + try { + output.writeMessageBegin('averageKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecord failed: unknown result'); + } + + averageKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordTime_args(params); + try { + output.writeMessageBegin('averageKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordTime failed: unknown result'); + } + + averageKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('averageKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordTimestr failed: unknown result'); + } + + averageKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_averageKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecords_args(params); + try { + output.writeMessageBegin('averageKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecords failed: unknown result'); + } + + averageKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordsTime_args(params); + try { + output.writeMessageBegin('averageKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordsTime failed: unknown result'); + } + + averageKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('averageKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyRecordsTimestr failed: unknown result'); + } + + averageKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKey(key, creds, transaction, environment); + }); + } + + send_averageKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKey_args(params); + try { + output.writeMessageBegin('averageKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKey failed: unknown result'); + } + + averageKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyTime_args(params); + try { + output.writeMessageBegin('averageKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyTime failed: unknown result'); + } + + averageKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyTimestr_args(params); + try { + output.writeMessageBegin('averageKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyTimestr failed: unknown result'); + } + + averageKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_averageKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCriteria_args(params); + try { + output.writeMessageBegin('averageKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCriteria failed: unknown result'); + } + + averageKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('averageKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCriteriaTime failed: unknown result'); + } + + averageKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('averageKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCriteriaTimestr failed: unknown result'); + } + + averageKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_averageKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCcl_args(params); + try { + output.writeMessageBegin('averageKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCcl failed: unknown result'); + } + + averageKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCclTime_args(params); + try { + output.writeMessageBegin('averageKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCclTime failed: unknown result'); + } + + averageKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_averageKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_averageKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_averageKeyCclTimestr_args(params); + try { + output.writeMessageBegin('averageKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_averageKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_averageKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('averageKeyCclTimestr failed: unknown result'); + } + + countKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_countKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecord_args(params); + try { + output.writeMessageBegin('countKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecord failed: unknown result'); + } + + countKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordTime_args(params); + try { + output.writeMessageBegin('countKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordTime failed: unknown result'); + } + + countKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('countKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordTimestr failed: unknown result'); + } + + countKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_countKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecords_args(params); + try { + output.writeMessageBegin('countKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecords failed: unknown result'); + } + + countKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordsTime_args(params); + try { + output.writeMessageBegin('countKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordsTime failed: unknown result'); + } + + countKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_countKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('countKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyRecordsTimestr failed: unknown result'); + } + + countKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKey(key, creds, transaction, environment); + }); + } + + send_countKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKey_args(params); + try { + output.writeMessageBegin('countKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKey failed: unknown result'); + } + + countKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_countKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyTime_args(params); + try { + output.writeMessageBegin('countKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyTime failed: unknown result'); + } + + countKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_countKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyTimestr_args(params); + try { + output.writeMessageBegin('countKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyTimestr failed: unknown result'); + } + + countKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_countKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCriteria_args(params); + try { + output.writeMessageBegin('countKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCriteria failed: unknown result'); + } + + countKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('countKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCriteriaTime failed: unknown result'); + } + + countKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('countKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCriteriaTimestr failed: unknown result'); + } + + countKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_countKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCcl_args(params); + try { + output.writeMessageBegin('countKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCcl failed: unknown result'); + } + + countKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCclTime_args(params); + try { + output.writeMessageBegin('countKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCclTime failed: unknown result'); + } + + countKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_countKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_countKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_countKeyCclTimestr_args(params); + try { + output.writeMessageBegin('countKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_countKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_countKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('countKeyCclTimestr failed: unknown result'); + } + + maxKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_maxKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecord_args(params); + try { + output.writeMessageBegin('maxKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecord failed: unknown result'); + } + + maxKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordTime_args(params); + try { + output.writeMessageBegin('maxKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordTime failed: unknown result'); + } + + maxKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('maxKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordTimestr failed: unknown result'); + } + + maxKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_maxKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecords_args(params); + try { + output.writeMessageBegin('maxKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecords failed: unknown result'); + } + + maxKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordsTime_args(params); + try { + output.writeMessageBegin('maxKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordsTime failed: unknown result'); + } + + maxKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('maxKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyRecordsTimestr failed: unknown result'); + } + + maxKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_maxKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCriteria_args(params); + try { + output.writeMessageBegin('maxKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCriteria failed: unknown result'); + } + + maxKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('maxKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCriteriaTime failed: unknown result'); + } + + maxKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('maxKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCriteriaTimestr failed: unknown result'); + } + + maxKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_maxKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCcl_args(params); + try { + output.writeMessageBegin('maxKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCcl failed: unknown result'); + } + + maxKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCclTime_args(params); + try { + output.writeMessageBegin('maxKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCclTime failed: unknown result'); + } + + maxKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyCclTimestr_args(params); + try { + output.writeMessageBegin('maxKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyCclTimestr failed: unknown result'); + } + + maxKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKey(key, creds, transaction, environment); + }); + } + + send_maxKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKey_args(params); + try { + output.writeMessageBegin('maxKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKey failed: unknown result'); + } + + maxKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyTime_args(params); + try { + output.writeMessageBegin('maxKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyTime failed: unknown result'); + } + + maxKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_maxKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_maxKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_maxKeyTimestr_args(params); + try { + output.writeMessageBegin('maxKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_maxKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_maxKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('maxKeyTimestr failed: unknown result'); + } + + minKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_minKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecord_args(params); + try { + output.writeMessageBegin('minKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecord failed: unknown result'); + } + + minKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordTime_args(params); + try { + output.writeMessageBegin('minKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordTime failed: unknown result'); + } + + minKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('minKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordTimestr failed: unknown result'); + } + + minKey (key, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKey(key, creds, transaction, environment); + }); + } + + send_minKey (key, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKey_args(params); + try { + output.writeMessageBegin('minKey', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKey (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKey_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKey failed: unknown result'); + } + + minKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordsTime_args(params); + try { + output.writeMessageBegin('minKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordsTime failed: unknown result'); + } + + minKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_minKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('minKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecordsTimestr failed: unknown result'); + } + + minKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_minKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCriteria_args(params); + try { + output.writeMessageBegin('minKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCriteria failed: unknown result'); + } + + minKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('minKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCriteriaTime failed: unknown result'); + } + + minKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('minKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCriteriaTimestr failed: unknown result'); + } + + minKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_minKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCcl_args(params); + try { + output.writeMessageBegin('minKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCcl failed: unknown result'); + } + + minKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCclTime_args(params); + try { + output.writeMessageBegin('minKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCclTime failed: unknown result'); + } + + minKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_minKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyCclTimestr_args(params); + try { + output.writeMessageBegin('minKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyCclTimestr failed: unknown result'); + } + + minKeyTime (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyTime(key, timestamp, creds, transaction, environment); + }); + } + + send_minKeyTime (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyTime_args(params); + try { + output.writeMessageBegin('minKeyTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyTime failed: unknown result'); + } + + minKeyTimestr (key, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyTimestr(key, timestamp, creds, transaction, environment); + }); + } + + send_minKeyTimestr (key, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyTimestr_args(params); + try { + output.writeMessageBegin('minKeyTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyTimestr failed: unknown result'); + } + + minKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_minKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_minKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_minKeyRecords_args(params); + try { + output.writeMessageBegin('minKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_minKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_minKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('minKeyRecords failed: unknown result'); + } + + navigateKeyRecord (key, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecord(key, record, creds, transaction, environment); + }); + } + + send_navigateKeyRecord (key, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecord_args(params); + try { + output.writeMessageBegin('navigateKeyRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecord failed: unknown result'); + } + + navigateKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordTime(key, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordTime (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordTime_args(params); + try { + output.writeMessageBegin('navigateKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordTime failed: unknown result'); + } + + navigateKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordTimestr failed: unknown result'); + } + + navigateKeysRecord (keys, record, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecord(keys, record, creds, transaction, environment); + }); + } + + send_navigateKeysRecord (keys, record, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecord_args(params); + try { + output.writeMessageBegin('navigateKeysRecord', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecord (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecord_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecord failed: unknown result'); + } + + navigateKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordTime(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordTime_args(params); + try { + output.writeMessageBegin('navigateKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordTime failed: unknown result'); + } + + navigateKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + record: record, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordTimestr failed: unknown result'); + } + + navigateKeysRecords (keys, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecords(keys, records, creds, transaction, environment); + }); + } + + send_navigateKeysRecords (keys, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecords_args(params); + try { + output.writeMessageBegin('navigateKeysRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecords failed: unknown result'); + } + + navigateKeyRecords (key, records, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecords(key, records, creds, transaction, environment); + }); + } + + send_navigateKeyRecords (key, records, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecords_args(params); + try { + output.writeMessageBegin('navigateKeyRecords', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecords (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecords_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecords failed: unknown result'); + } + + navigateKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordsTime(key, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordsTime_args(params); + try { + output.writeMessageBegin('navigateKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordsTime failed: unknown result'); + } + + navigateKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyRecordsTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyRecordsTimestr failed: unknown result'); + } + + navigateKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordsTime_args(params); + try { + output.writeMessageBegin('navigateKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordsTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordsTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordsTime failed: unknown result'); + } + + navigateKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + records: records, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysRecordsTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysRecordsTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysRecordsTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysRecordsTimestr failed: unknown result'); + } + + navigateKeyCcl (key, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCcl(key, ccl, creds, transaction, environment); + }); + } + + send_navigateKeyCcl (key, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCcl_args(params); + try { + output.writeMessageBegin('navigateKeyCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCcl failed: unknown result'); + } + + navigateKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCclTime(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCclTime_args(params); + try { + output.writeMessageBegin('navigateKeyCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCclTime failed: unknown result'); + } + + navigateKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCclTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCclTimestr failed: unknown result'); + } + + navigateKeysCcl (keys, ccl, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCcl(keys, ccl, creds, transaction, environment); + }); + } + + send_navigateKeysCcl (keys, ccl, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCcl_args(params); + try { + output.writeMessageBegin('navigateKeysCcl', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCcl (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCcl_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCcl failed: unknown result'); + } + + navigateKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCclTime_args(params); + try { + output.writeMessageBegin('navigateKeysCclTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCclTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCclTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCclTime failed: unknown result'); + } + + navigateKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + ccl: ccl, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCclTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCclTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCclTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCclTimestr failed: unknown result'); + } + + navigateKeyCriteria (key, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCriteria(key, criteria, creds, transaction, environment); + }); + } + + send_navigateKeyCriteria (key, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCriteria_args(params); + try { + output.writeMessageBegin('navigateKeyCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCriteria failed: unknown result'); + } + + navigateKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCriteriaTime_args(params); + try { + output.writeMessageBegin('navigateKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCriteriaTime failed: unknown result'); + } + + navigateKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + key: key, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeyCriteriaTimestr_args(params); + try { + output.writeMessageBegin('navigateKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeyCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeyCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeyCriteriaTimestr failed: unknown result'); + } + + navigateKeysCriteria (keys, criteria, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCriteria(keys, criteria, creds, transaction, environment); + }); + } + + send_navigateKeysCriteria (keys, criteria, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCriteria_args(params); + try { + output.writeMessageBegin('navigateKeysCriteria', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCriteria (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCriteria_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCriteria failed: unknown result'); + } + + navigateKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCriteriaTime_args(params); + try { + output.writeMessageBegin('navigateKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCriteriaTime (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCriteriaTime_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCriteriaTime failed: unknown result'); + } + + navigateKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_navigateKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); + }); + } + + send_navigateKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { + const output = new this.pClass(this.output); + const params = { + keys: keys, + criteria: criteria, + timestamp: timestamp, + creds: creds, + transaction: transaction, + environment: environment + }; + const args = new ConcourseService_navigateKeysCriteriaTimestr_args(params); + try { + output.writeMessageBegin('navigateKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_navigateKeysCriteriaTimestr (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_navigateKeysCriteriaTimestr_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('navigateKeysCriteriaTimestr failed: unknown result'); + } + + getServerEnvironment (creds, token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getServerEnvironment(creds, token, environment); + }); + } + + send_getServerEnvironment (creds, token, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + token: token, + environment: environment + }; + const args = new ConcourseService_getServerEnvironment_args(params); + try { + output.writeMessageBegin('getServerEnvironment', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getServerEnvironment (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getServerEnvironment_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getServerEnvironment failed: unknown result'); + } + + getServerVersion () { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_getServerVersion(); + }); + } + + send_getServerVersion () { + const output = new this.pClass(this.output); + const args = new ConcourseService_getServerVersion_args(); + try { + output.writeMessageBegin('getServerVersion', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_getServerVersion (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_getServerVersion_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('getServerVersion failed: unknown result'); + } + + time (creds, token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_time(creds, token, environment); + }); + } + + send_time (creds, token, environment) { + const output = new this.pClass(this.output); + const params = { + creds: creds, + token: token, + environment: environment + }; + const args = new ConcourseService_time_args(params); + try { + output.writeMessageBegin('time', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_time (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_time_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('time failed: unknown result'); + } + + timePhrase (phrase, creds, token, environment) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_timePhrase(phrase, creds, token, environment); + }); + } + + send_timePhrase (phrase, creds, token, environment) { + const output = new this.pClass(this.output); + const params = { + phrase: phrase, + creds: creds, + token: token, + environment: environment + }; + const args = new ConcourseService_timePhrase_args(params); + try { + output.writeMessageBegin('timePhrase', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_timePhrase (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_timePhrase_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.ex3) { + return callback(result.ex3); + } + if (null !== result.ex4) { + return callback(result.ex4); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('timePhrase failed: unknown result'); + } + + invokeManagement (method, params, creds) { + this._seqid = this.new_seqid(); + const self = this; + return new Promise((resolve, reject) => { + self._reqs[self.seqid()] = (error, result) => { + return error ? reject(error) : resolve(result); + }; + self.send_invokeManagement(method, params, creds); + }); + } + + send_invokeManagement (method, params, creds) { + const output = new this.pClass(this.output); + const params = { + method: method, + params: params, + creds: creds + }; + const args = new ConcourseService_invokeManagement_args(params); + try { + output.writeMessageBegin('invokeManagement', Thrift.MessageType.CALL, this.seqid()); + args.write(output); + output.writeMessageEnd(); + return this.output.flush(); + } + catch (e) { + delete this._reqs[this.seqid()]; + if (typeof output.reset === 'function') { + output.reset(); + } + throw e; + } + } + + recv_invokeManagement (input, mtype, rseqid) { + const callback = this._reqs[rseqid] || function() {}; + delete this._reqs[rseqid]; + if (mtype == Thrift.MessageType.EXCEPTION) { + const x = new Thrift.TApplicationException(); + x.read(input); + input.readMessageEnd(); + return callback(x); + } + const result = new ConcourseService_invokeManagement_result(); + result.read(input); + input.readMessageEnd(); + + if (null !== result.ex) { + return callback(result.ex); + } + if (null !== result.ex2) { + return callback(result.ex2); + } + if (null !== result.success) { + return callback(null, result.success); + } + return callback('invokeManagement failed: unknown result'); + } +}; +const ConcourseServiceProcessor = exports.Processor = class { + constructor(handler) { + this._handler = handler; + } + process (input, output) { + const r = input.readMessageBegin(); + if (this['process_' + r.fname]) { + return this['process_' + r.fname].call(this, r.rseqid, input, output); + } else { + input.skip(Thrift.Type.STRUCT); + input.readMessageEnd(); + const x = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN_METHOD, 'Unknown function ' + r.fname); + output.writeMessageBegin(r.fname, Thrift.MessageType.EXCEPTION, r.rseqid); + x.write(output); + output.writeMessageEnd(); + output.flush(); + } + } + process_abort (seqid, input, output) { + const args = new ConcourseService_abort_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.abort.length === 3) { + Promise.resolve(this._handler.abort.bind(this._handler)( + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_abort_result({success: result}); + output.writeMessageBegin("abort", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException) { + result = new ConcourseService_abort_result(err); + output.writeMessageBegin("abort", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("abort", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.abort(args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException) { + result_obj = new ConcourseService_abort_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("abort", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("abort", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_addKeyValue (seqid, input, output) { + const args = new ConcourseService_addKeyValue_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.addKeyValue.length === 5) { + Promise.resolve(this._handler.addKeyValue.bind(this._handler)( + args.key, + args.value, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_addKeyValue_result({success: result}); + output.writeMessageBegin("addKeyValue", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_addKeyValue_result(err); + output.writeMessageBegin("addKeyValue", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("addKeyValue", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.addKeyValue(args.key, args.value, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_addKeyValue_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("addKeyValue", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("addKeyValue", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_addKeyValueRecord (seqid, input, output) { + const args = new ConcourseService_addKeyValueRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.addKeyValueRecord.length === 6) { + Promise.resolve(this._handler.addKeyValueRecord.bind(this._handler)( + args.key, + args.value, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_addKeyValueRecord_result({success: result}); + output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_addKeyValueRecord_result(err); + output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.addKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_addKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_addKeyValueRecords (seqid, input, output) { + const args = new ConcourseService_addKeyValueRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.addKeyValueRecords.length === 6) { + Promise.resolve(this._handler.addKeyValueRecords.bind(this._handler)( + args.key, + args.value, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_addKeyValueRecords_result({success: result}); + output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_addKeyValueRecords_result(err); + output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.addKeyValueRecords(args.key, args.value, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_addKeyValueRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditRecord (seqid, input, output) { + const args = new ConcourseService_auditRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditRecord.length === 4) { + Promise.resolve(this._handler.auditRecord.bind(this._handler)( + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditRecord_result({success: result}); + output.writeMessageBegin("auditRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditRecord_result(err); + output.writeMessageBegin("auditRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditRecordStart (seqid, input, output) { + const args = new ConcourseService_auditRecordStart_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditRecordStart.length === 5) { + Promise.resolve(this._handler.auditRecordStart.bind(this._handler)( + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditRecordStart_result({success: result}); + output.writeMessageBegin("auditRecordStart", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditRecordStart_result(err); + output.writeMessageBegin("auditRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditRecordStart(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditRecordStartstr (seqid, input, output) { + const args = new ConcourseService_auditRecordStartstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditRecordStartstr.length === 5) { + Promise.resolve(this._handler.auditRecordStartstr.bind(this._handler)( + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditRecordStartstr_result({success: result}); + output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditRecordStartstr_result(err); + output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditRecordStartstr(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditRecordStartEnd (seqid, input, output) { + const args = new ConcourseService_auditRecordStartEnd_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditRecordStartEnd.length === 6) { + Promise.resolve(this._handler.auditRecordStartEnd.bind(this._handler)( + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditRecordStartEnd_result({success: result}); + output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditRecordStartEnd_result(err); + output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditRecordStartEnd(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditRecordStartstrEndstr (seqid, input, output) { + const args = new ConcourseService_auditRecordStartstrEndstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditRecordStartstrEndstr.length === 6) { + Promise.resolve(this._handler.auditRecordStartstrEndstr.bind(this._handler)( + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditRecordStartstrEndstr_result({success: result}); + output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditRecordStartstrEndstr_result(err); + output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditRecordStartstrEndstr(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditKeyRecord (seqid, input, output) { + const args = new ConcourseService_auditKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditKeyRecord.length === 5) { + Promise.resolve(this._handler.auditKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditKeyRecord_result({success: result}); + output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditKeyRecord_result(err); + output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditKeyRecordStart (seqid, input, output) { + const args = new ConcourseService_auditKeyRecordStart_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditKeyRecordStart.length === 6) { + Promise.resolve(this._handler.auditKeyRecordStart.bind(this._handler)( + args.key, + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditKeyRecordStart_result({success: result}); + output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditKeyRecordStart_result(err); + output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditKeyRecordStart(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditKeyRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditKeyRecordStartstr (seqid, input, output) { + const args = new ConcourseService_auditKeyRecordStartstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditKeyRecordStartstr.length === 6) { + Promise.resolve(this._handler.auditKeyRecordStartstr.bind(this._handler)( + args.key, + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditKeyRecordStartstr_result({success: result}); + output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditKeyRecordStartstr_result(err); + output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditKeyRecordStartstr(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditKeyRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditKeyRecordStartEnd (seqid, input, output) { + const args = new ConcourseService_auditKeyRecordStartEnd_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditKeyRecordStartEnd.length === 7) { + Promise.resolve(this._handler.auditKeyRecordStartEnd.bind(this._handler)( + args.key, + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditKeyRecordStartEnd_result({success: result}); + output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditKeyRecordStartEnd_result(err); + output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditKeyRecordStartEnd(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditKeyRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_auditKeyRecordStartstrEndstr (seqid, input, output) { + const args = new ConcourseService_auditKeyRecordStartstrEndstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.auditKeyRecordStartstrEndstr.length === 7) { + Promise.resolve(this._handler.auditKeyRecordStartstrEndstr.bind(this._handler)( + args.key, + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_auditKeyRecordStartstrEndstr_result({success: result}); + output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_auditKeyRecordStartstrEndstr_result(err); + output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.auditKeyRecordStartstrEndstr(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_auditKeyRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_browseKey (seqid, input, output) { + const args = new ConcourseService_browseKey_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.browseKey.length === 4) { + Promise.resolve(this._handler.browseKey.bind(this._handler)( + args.key, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_browseKey_result({success: result}); + output.writeMessageBegin("browseKey", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_browseKey_result(err); + output.writeMessageBegin("browseKey", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKey", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.browseKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_browseKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("browseKey", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKey", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_browseKeys (seqid, input, output) { + const args = new ConcourseService_browseKeys_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.browseKeys.length === 4) { + Promise.resolve(this._handler.browseKeys.bind(this._handler)( + args.keys, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_browseKeys_result({success: result}); + output.writeMessageBegin("browseKeys", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_browseKeys_result(err); + output.writeMessageBegin("browseKeys", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeys", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.browseKeys(args.keys, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_browseKeys_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("browseKeys", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeys", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_browseKeyTime (seqid, input, output) { + const args = new ConcourseService_browseKeyTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.browseKeyTime.length === 5) { + Promise.resolve(this._handler.browseKeyTime.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_browseKeyTime_result({success: result}); + output.writeMessageBegin("browseKeyTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_browseKeyTime_result(err); + output.writeMessageBegin("browseKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.browseKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_browseKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("browseKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_browseKeyTimestr (seqid, input, output) { + const args = new ConcourseService_browseKeyTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.browseKeyTimestr.length === 5) { + Promise.resolve(this._handler.browseKeyTimestr.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_browseKeyTimestr_result({success: result}); + output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_browseKeyTimestr_result(err); + output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.browseKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_browseKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_browseKeysTime (seqid, input, output) { + const args = new ConcourseService_browseKeysTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.browseKeysTime.length === 5) { + Promise.resolve(this._handler.browseKeysTime.bind(this._handler)( + args.keys, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_browseKeysTime_result({success: result}); + output.writeMessageBegin("browseKeysTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_browseKeysTime_result(err); + output.writeMessageBegin("browseKeysTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeysTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.browseKeysTime(args.keys, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_browseKeysTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("browseKeysTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeysTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_browseKeysTimestr (seqid, input, output) { + const args = new ConcourseService_browseKeysTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.browseKeysTimestr.length === 5) { + Promise.resolve(this._handler.browseKeysTimestr.bind(this._handler)( + args.keys, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_browseKeysTimestr_result({success: result}); + output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_browseKeysTimestr_result(err); + output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.browseKeysTimestr(args.keys, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_browseKeysTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_chronologizeKeyRecord (seqid, input, output) { + const args = new ConcourseService_chronologizeKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.chronologizeKeyRecord.length === 5) { + Promise.resolve(this._handler.chronologizeKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_chronologizeKeyRecord_result({success: result}); + output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_chronologizeKeyRecord_result(err); + output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.chronologizeKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_chronologizeKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_chronologizeKeyRecordStart (seqid, input, output) { + const args = new ConcourseService_chronologizeKeyRecordStart_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.chronologizeKeyRecordStart.length === 6) { + Promise.resolve(this._handler.chronologizeKeyRecordStart.bind(this._handler)( + args.key, + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_chronologizeKeyRecordStart_result({success: result}); + output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_chronologizeKeyRecordStart_result(err); + output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.chronologizeKeyRecordStart(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_chronologizeKeyRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_chronologizeKeyRecordStartstr (seqid, input, output) { + const args = new ConcourseService_chronologizeKeyRecordStartstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.chronologizeKeyRecordStartstr.length === 6) { + Promise.resolve(this._handler.chronologizeKeyRecordStartstr.bind(this._handler)( + args.key, + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_chronologizeKeyRecordStartstr_result({success: result}); + output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_chronologizeKeyRecordStartstr_result(err); + output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.chronologizeKeyRecordStartstr(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_chronologizeKeyRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_chronologizeKeyRecordStartEnd (seqid, input, output) { + const args = new ConcourseService_chronologizeKeyRecordStartEnd_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.chronologizeKeyRecordStartEnd.length === 7) { + Promise.resolve(this._handler.chronologizeKeyRecordStartEnd.bind(this._handler)( + args.key, + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_chronologizeKeyRecordStartEnd_result({success: result}); + output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_chronologizeKeyRecordStartEnd_result(err); + output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.chronologizeKeyRecordStartEnd(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_chronologizeKeyRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_chronologizeKeyRecordStartstrEndstr (seqid, input, output) { + const args = new ConcourseService_chronologizeKeyRecordStartstrEndstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.chronologizeKeyRecordStartstrEndstr.length === 7) { + Promise.resolve(this._handler.chronologizeKeyRecordStartstrEndstr.bind(this._handler)( + args.key, + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result({success: result}); + output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result(err); + output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.chronologizeKeyRecordStartstrEndstr(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_clearRecord (seqid, input, output) { + const args = new ConcourseService_clearRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.clearRecord.length === 4) { + Promise.resolve(this._handler.clearRecord.bind(this._handler)( + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_clearRecord_result({success: result}); + output.writeMessageBegin("clearRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_clearRecord_result(err); + output.writeMessageBegin("clearRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.clearRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_clearRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("clearRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_clearRecords (seqid, input, output) { + const args = new ConcourseService_clearRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.clearRecords.length === 4) { + Promise.resolve(this._handler.clearRecords.bind(this._handler)( + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_clearRecords_result({success: result}); + output.writeMessageBegin("clearRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_clearRecords_result(err); + output.writeMessageBegin("clearRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.clearRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_clearRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("clearRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_clearKeyRecord (seqid, input, output) { + const args = new ConcourseService_clearKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.clearKeyRecord.length === 5) { + Promise.resolve(this._handler.clearKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_clearKeyRecord_result({success: result}); + output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_clearKeyRecord_result(err); + output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.clearKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_clearKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_clearKeysRecord (seqid, input, output) { + const args = new ConcourseService_clearKeysRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.clearKeysRecord.length === 5) { + Promise.resolve(this._handler.clearKeysRecord.bind(this._handler)( + args.keys, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_clearKeysRecord_result({success: result}); + output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_clearKeysRecord_result(err); + output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.clearKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_clearKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_clearKeyRecords (seqid, input, output) { + const args = new ConcourseService_clearKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.clearKeyRecords.length === 5) { + Promise.resolve(this._handler.clearKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_clearKeyRecords_result({success: result}); + output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_clearKeyRecords_result(err); + output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.clearKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_clearKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_clearKeysRecords (seqid, input, output) { + const args = new ConcourseService_clearKeysRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.clearKeysRecords.length === 5) { + Promise.resolve(this._handler.clearKeysRecords.bind(this._handler)( + args.keys, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_clearKeysRecords_result({success: result}); + output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_clearKeysRecords_result(err); + output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.clearKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_clearKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_commit (seqid, input, output) { + const args = new ConcourseService_commit_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.commit.length === 3) { + Promise.resolve(this._handler.commit.bind(this._handler)( + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_commit_result({success: result}); + output.writeMessageBegin("commit", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_commit_result(err); + output.writeMessageBegin("commit", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("commit", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.commit(args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_commit_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("commit", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("commit", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describe (seqid, input, output) { + const args = new ConcourseService_describe_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describe.length === 3) { + Promise.resolve(this._handler.describe.bind(this._handler)( + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describe_result({success: result}); + output.writeMessageBegin("describe", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describe_result(err); + output.writeMessageBegin("describe", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describe", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describe(args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describe_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describe", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describe", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeTime (seqid, input, output) { + const args = new ConcourseService_describeTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeTime.length === 4) { + Promise.resolve(this._handler.describeTime.bind(this._handler)( + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeTime_result({success: result}); + output.writeMessageBegin("describeTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeTime_result(err); + output.writeMessageBegin("describeTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeTime(args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeTimestr (seqid, input, output) { + const args = new ConcourseService_describeTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeTimestr.length === 4) { + Promise.resolve(this._handler.describeTimestr.bind(this._handler)( + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeTimestr_result({success: result}); + output.writeMessageBegin("describeTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeTimestr_result(err); + output.writeMessageBegin("describeTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeTimestr(args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeRecord (seqid, input, output) { + const args = new ConcourseService_describeRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeRecord.length === 4) { + Promise.resolve(this._handler.describeRecord.bind(this._handler)( + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeRecord_result({success: result}); + output.writeMessageBegin("describeRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeRecord_result(err); + output.writeMessageBegin("describeRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeRecordTime (seqid, input, output) { + const args = new ConcourseService_describeRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeRecordTime.length === 5) { + Promise.resolve(this._handler.describeRecordTime.bind(this._handler)( + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeRecordTime_result({success: result}); + output.writeMessageBegin("describeRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeRecordTime_result(err); + output.writeMessageBegin("describeRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeRecordTime(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeRecordTimestr (seqid, input, output) { + const args = new ConcourseService_describeRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeRecordTimestr.length === 5) { + Promise.resolve(this._handler.describeRecordTimestr.bind(this._handler)( + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeRecordTimestr_result({success: result}); + output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeRecordTimestr_result(err); + output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeRecordTimestr(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeRecords (seqid, input, output) { + const args = new ConcourseService_describeRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeRecords.length === 4) { + Promise.resolve(this._handler.describeRecords.bind(this._handler)( + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeRecords_result({success: result}); + output.writeMessageBegin("describeRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeRecords_result(err); + output.writeMessageBegin("describeRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeRecordsTime (seqid, input, output) { + const args = new ConcourseService_describeRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeRecordsTime.length === 5) { + Promise.resolve(this._handler.describeRecordsTime.bind(this._handler)( + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeRecordsTime_result({success: result}); + output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeRecordsTime_result(err); + output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeRecordsTime(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_describeRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_describeRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.describeRecordsTimestr.length === 5) { + Promise.resolve(this._handler.describeRecordsTimestr.bind(this._handler)( + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_describeRecordsTimestr_result({success: result}); + output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_describeRecordsTimestr_result(err); + output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.describeRecordsTimestr(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_describeRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffRecordStart (seqid, input, output) { + const args = new ConcourseService_diffRecordStart_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffRecordStart.length === 5) { + Promise.resolve(this._handler.diffRecordStart.bind(this._handler)( + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffRecordStart_result({success: result}); + output.writeMessageBegin("diffRecordStart", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffRecordStart_result(err); + output.writeMessageBegin("diffRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffRecordStart(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffRecordStartstr (seqid, input, output) { + const args = new ConcourseService_diffRecordStartstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffRecordStartstr.length === 5) { + Promise.resolve(this._handler.diffRecordStartstr.bind(this._handler)( + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffRecordStartstr_result({success: result}); + output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffRecordStartstr_result(err); + output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffRecordStartstr(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffRecordStartEnd (seqid, input, output) { + const args = new ConcourseService_diffRecordStartEnd_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffRecordStartEnd.length === 6) { + Promise.resolve(this._handler.diffRecordStartEnd.bind(this._handler)( + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffRecordStartEnd_result({success: result}); + output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffRecordStartEnd_result(err); + output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffRecordStartEnd(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffRecordStartstrEndstr (seqid, input, output) { + const args = new ConcourseService_diffRecordStartstrEndstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffRecordStartstrEndstr.length === 6) { + Promise.resolve(this._handler.diffRecordStartstrEndstr.bind(this._handler)( + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffRecordStartstrEndstr_result({success: result}); + output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffRecordStartstrEndstr_result(err); + output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffRecordStartstrEndstr(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyRecordStart (seqid, input, output) { + const args = new ConcourseService_diffKeyRecordStart_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyRecordStart.length === 6) { + Promise.resolve(this._handler.diffKeyRecordStart.bind(this._handler)( + args.key, + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyRecordStart_result({success: result}); + output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyRecordStart_result(err); + output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyRecordStart(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyRecordStartstr (seqid, input, output) { + const args = new ConcourseService_diffKeyRecordStartstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyRecordStartstr.length === 6) { + Promise.resolve(this._handler.diffKeyRecordStartstr.bind(this._handler)( + args.key, + args.record, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyRecordStartstr_result({success: result}); + output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyRecordStartstr_result(err); + output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyRecordStartstr(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyRecordStartEnd (seqid, input, output) { + const args = new ConcourseService_diffKeyRecordStartEnd_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyRecordStartEnd.length === 7) { + Promise.resolve(this._handler.diffKeyRecordStartEnd.bind(this._handler)( + args.key, + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyRecordStartEnd_result({success: result}); + output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyRecordStartEnd_result(err); + output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyRecordStartEnd(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyRecordStartstrEndstr (seqid, input, output) { + const args = new ConcourseService_diffKeyRecordStartstrEndstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyRecordStartstrEndstr.length === 7) { + Promise.resolve(this._handler.diffKeyRecordStartstrEndstr.bind(this._handler)( + args.key, + args.record, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyRecordStartstrEndstr_result({success: result}); + output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyRecordStartstrEndstr_result(err); + output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyRecordStartstrEndstr(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyStart (seqid, input, output) { + const args = new ConcourseService_diffKeyStart_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyStart.length === 5) { + Promise.resolve(this._handler.diffKeyStart.bind(this._handler)( + args.key, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyStart_result({success: result}); + output.writeMessageBegin("diffKeyStart", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyStart_result(err); + output.writeMessageBegin("diffKeyStart", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStart", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyStart(args.key, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyStart", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStart", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyStartstr (seqid, input, output) { + const args = new ConcourseService_diffKeyStartstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyStartstr.length === 5) { + Promise.resolve(this._handler.diffKeyStartstr.bind(this._handler)( + args.key, + args.start, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyStartstr_result({success: result}); + output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyStartstr_result(err); + output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyStartstr(args.key, args.start, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyStartEnd (seqid, input, output) { + const args = new ConcourseService_diffKeyStartEnd_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyStartEnd.length === 6) { + Promise.resolve(this._handler.diffKeyStartEnd.bind(this._handler)( + args.key, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyStartEnd_result({success: result}); + output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyStartEnd_result(err); + output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyStartEnd(args.key, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_diffKeyStartstrEndstr (seqid, input, output) { + const args = new ConcourseService_diffKeyStartstrEndstr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.diffKeyStartstrEndstr.length === 6) { + Promise.resolve(this._handler.diffKeyStartstrEndstr.bind(this._handler)( + args.key, + args.start, + args.tend, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_diffKeyStartstrEndstr_result({success: result}); + output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_diffKeyStartstrEndstr_result(err); + output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.diffKeyStartstrEndstr(args.key, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_diffKeyStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_invokePlugin (seqid, input, output) { + const args = new ConcourseService_invokePlugin_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.invokePlugin.length === 6) { + Promise.resolve(this._handler.invokePlugin.bind(this._handler)( + args.id, + args.method, + args.params, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_invokePlugin_result({success: result}); + output.writeMessageBegin("invokePlugin", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_invokePlugin_result(err); + output.writeMessageBegin("invokePlugin", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("invokePlugin", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.invokePlugin(args.id, args.method, args.params, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_invokePlugin_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("invokePlugin", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("invokePlugin", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_login (seqid, input, output) { + const args = new ConcourseService_login_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.login.length === 3) { + Promise.resolve(this._handler.login.bind(this._handler)( + args.username, + args.password, + args.environment + )).then(result => { + const result_obj = new ConcourseService_login_result({success: result}); + output.writeMessageBegin("login", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_login_result(err); + output.writeMessageBegin("login", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("login", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.login(args.username, args.password, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_login_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("login", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("login", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_logout (seqid, input, output) { + const args = new ConcourseService_logout_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.logout.length === 2) { + Promise.resolve(this._handler.logout.bind(this._handler)( + args.token, + args.environment + )).then(result => { + const result_obj = new ConcourseService_logout_result({success: result}); + output.writeMessageBegin("logout", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_logout_result(err); + output.writeMessageBegin("logout", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("logout", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.logout(args.token, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_logout_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("logout", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("logout", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_stage (seqid, input, output) { + const args = new ConcourseService_stage_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.stage.length === 2) { + Promise.resolve(this._handler.stage.bind(this._handler)( + args.token, + args.environment + )).then(result => { + const result_obj = new ConcourseService_stage_result({success: result}); + output.writeMessageBegin("stage", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_stage_result(err); + output.writeMessageBegin("stage", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("stage", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.stage(args.token, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_stage_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("stage", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("stage", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_insertJson (seqid, input, output) { + const args = new ConcourseService_insertJson_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.insertJson.length === 4) { + Promise.resolve(this._handler.insertJson.bind(this._handler)( + args.json, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_insertJson_result({success: result}); + output.writeMessageBegin("insertJson", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_insertJson_result(err); + output.writeMessageBegin("insertJson", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("insertJson", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.insertJson(args.json, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_insertJson_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("insertJson", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("insertJson", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_insertJsonRecord (seqid, input, output) { + const args = new ConcourseService_insertJsonRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.insertJsonRecord.length === 5) { + Promise.resolve(this._handler.insertJsonRecord.bind(this._handler)( + args.json, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_insertJsonRecord_result({success: result}); + output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_insertJsonRecord_result(err); + output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.insertJsonRecord(args.json, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_insertJsonRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_insertJsonRecords (seqid, input, output) { + const args = new ConcourseService_insertJsonRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.insertJsonRecords.length === 5) { + Promise.resolve(this._handler.insertJsonRecords.bind(this._handler)( + args.json, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_insertJsonRecords_result({success: result}); + output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_insertJsonRecords_result(err); + output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.insertJsonRecords(args.json, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_insertJsonRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_removeKeyValueRecord (seqid, input, output) { + const args = new ConcourseService_removeKeyValueRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.removeKeyValueRecord.length === 6) { + Promise.resolve(this._handler.removeKeyValueRecord.bind(this._handler)( + args.key, + args.value, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_removeKeyValueRecord_result({success: result}); + output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_removeKeyValueRecord_result(err); + output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.removeKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_removeKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_removeKeyValueRecords (seqid, input, output) { + const args = new ConcourseService_removeKeyValueRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.removeKeyValueRecords.length === 6) { + Promise.resolve(this._handler.removeKeyValueRecords.bind(this._handler)( + args.key, + args.value, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_removeKeyValueRecords_result({success: result}); + output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_removeKeyValueRecords_result(err); + output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.removeKeyValueRecords(args.key, args.value, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_removeKeyValueRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_setKeyValueRecord (seqid, input, output) { + const args = new ConcourseService_setKeyValueRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.setKeyValueRecord.length === 6) { + Promise.resolve(this._handler.setKeyValueRecord.bind(this._handler)( + args.key, + args.value, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_setKeyValueRecord_result({success: result}); + output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_setKeyValueRecord_result(err); + output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.setKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_setKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_setKeyValue (seqid, input, output) { + const args = new ConcourseService_setKeyValue_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.setKeyValue.length === 5) { + Promise.resolve(this._handler.setKeyValue.bind(this._handler)( + args.key, + args.value, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_setKeyValue_result({success: result}); + output.writeMessageBegin("setKeyValue", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_setKeyValue_result(err); + output.writeMessageBegin("setKeyValue", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("setKeyValue", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.setKeyValue(args.key, args.value, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_setKeyValue_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("setKeyValue", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("setKeyValue", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_setKeyValueRecords (seqid, input, output) { + const args = new ConcourseService_setKeyValueRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.setKeyValueRecords.length === 6) { + Promise.resolve(this._handler.setKeyValueRecords.bind(this._handler)( + args.key, + args.value, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_setKeyValueRecords_result({success: result}); + output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_setKeyValueRecords_result(err); + output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.setKeyValueRecords(args.key, args.value, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_setKeyValueRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_reconcileKeyRecordValues (seqid, input, output) { + const args = new ConcourseService_reconcileKeyRecordValues_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.reconcileKeyRecordValues.length === 6) { + Promise.resolve(this._handler.reconcileKeyRecordValues.bind(this._handler)( + args.key, + args.record, + args.values, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_reconcileKeyRecordValues_result({success: result}); + output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_reconcileKeyRecordValues_result(err); + output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.reconcileKeyRecordValues(args.key, args.record, args.values, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_reconcileKeyRecordValues_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_inventory (seqid, input, output) { + const args = new ConcourseService_inventory_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.inventory.length === 3) { + Promise.resolve(this._handler.inventory.bind(this._handler)( + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_inventory_result({success: result}); + output.writeMessageBegin("inventory", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_inventory_result(err); + output.writeMessageBegin("inventory", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("inventory", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.inventory(args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_inventory_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("inventory", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("inventory", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectRecord (seqid, input, output) { + const args = new ConcourseService_selectRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectRecord.length === 4) { + Promise.resolve(this._handler.selectRecord.bind(this._handler)( + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectRecord_result({success: result}); + output.writeMessageBegin("selectRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectRecord_result(err); + output.writeMessageBegin("selectRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectRecords (seqid, input, output) { + const args = new ConcourseService_selectRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectRecords.length === 4) { + Promise.resolve(this._handler.selectRecords.bind(this._handler)( + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectRecords_result({success: result}); + output.writeMessageBegin("selectRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectRecords_result(err); + output.writeMessageBegin("selectRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectRecordTime (seqid, input, output) { + const args = new ConcourseService_selectRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectRecordTime.length === 5) { + Promise.resolve(this._handler.selectRecordTime.bind(this._handler)( + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectRecordTime_result({success: result}); + output.writeMessageBegin("selectRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectRecordTime_result(err); + output.writeMessageBegin("selectRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectRecordTime(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectRecordTimestr (seqid, input, output) { + const args = new ConcourseService_selectRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectRecordTimestr.length === 5) { + Promise.resolve(this._handler.selectRecordTimestr.bind(this._handler)( + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectRecordTimestr_result({success: result}); + output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectRecordTimestr_result(err); + output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectRecordTimestr(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectRecordsTime (seqid, input, output) { + const args = new ConcourseService_selectRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectRecordsTime.length === 5) { + Promise.resolve(this._handler.selectRecordsTime.bind(this._handler)( + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectRecordsTime_result({success: result}); + output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectRecordsTime_result(err); + output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectRecordsTime(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_selectRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectRecordsTimestr.length === 5) { + Promise.resolve(this._handler.selectRecordsTimestr.bind(this._handler)( + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectRecordsTimestr_result({success: result}); + output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectRecordsTimestr_result(err); + output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectRecordsTimestr(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyRecord (seqid, input, output) { + const args = new ConcourseService_selectKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyRecord.length === 5) { + Promise.resolve(this._handler.selectKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyRecord_result({success: result}); + output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyRecord_result(err); + output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_selectKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyRecordTime.length === 6) { + Promise.resolve(this._handler.selectKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyRecordTime_result({success: result}); + output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyRecordTime_result(err); + output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.selectKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyRecordTimestr_result(err); + output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysRecord (seqid, input, output) { + const args = new ConcourseService_selectKeysRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysRecord.length === 5) { + Promise.resolve(this._handler.selectKeysRecord.bind(this._handler)( + args.keys, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysRecord_result({success: result}); + output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysRecord_result(err); + output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysRecordTime (seqid, input, output) { + const args = new ConcourseService_selectKeysRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysRecordTime.length === 6) { + Promise.resolve(this._handler.selectKeysRecordTime.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysRecordTime_result({success: result}); + output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysRecordTime_result(err); + output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysRecordTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeysRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysRecordTimestr.length === 6) { + Promise.resolve(this._handler.selectKeysRecordTimestr.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysRecordTimestr_result({success: result}); + output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysRecordTimestr_result(err); + output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysRecords (seqid, input, output) { + const args = new ConcourseService_selectKeysRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysRecords.length === 5) { + Promise.resolve(this._handler.selectKeysRecords.bind(this._handler)( + args.keys, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysRecords_result({success: result}); + output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysRecords_result(err); + output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyRecords (seqid, input, output) { + const args = new ConcourseService_selectKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyRecords.length === 5) { + Promise.resolve(this._handler.selectKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyRecords_result({success: result}); + output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyRecords_result(err); + output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_selectKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.selectKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyRecordsTime_result({success: result}); + output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyRecordsTime_result(err); + output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.selectKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyRecordsTimestr_result(err); + output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysRecordsTime (seqid, input, output) { + const args = new ConcourseService_selectKeysRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysRecordsTime.length === 6) { + Promise.resolve(this._handler.selectKeysRecordsTime.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysRecordsTime_result({success: result}); + output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysRecordsTime_result(err); + output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeysRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysRecordsTimestr.length === 6) { + Promise.resolve(this._handler.selectKeysRecordsTimestr.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysRecordsTimestr_result({success: result}); + output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysRecordsTimestr_result(err); + output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectCriteria (seqid, input, output) { + const args = new ConcourseService_selectCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectCriteria.length === 4) { + Promise.resolve(this._handler.selectCriteria.bind(this._handler)( + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectCriteria_result({success: result}); + output.writeMessageBegin("selectCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectCriteria_result(err); + output.writeMessageBegin("selectCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectCriteria(args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectCcl (seqid, input, output) { + const args = new ConcourseService_selectCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectCcl.length === 4) { + Promise.resolve(this._handler.selectCcl.bind(this._handler)( + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectCcl_result({success: result}); + output.writeMessageBegin("selectCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectCcl_result(err); + output.writeMessageBegin("selectCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectCcl(args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectCriteriaTime (seqid, input, output) { + const args = new ConcourseService_selectCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectCriteriaTime.length === 5) { + Promise.resolve(this._handler.selectCriteriaTime.bind(this._handler)( + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectCriteriaTime_result({success: result}); + output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectCriteriaTime_result(err); + output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectCriteriaTime(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_selectCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectCriteriaTimestr.length === 5) { + Promise.resolve(this._handler.selectCriteriaTimestr.bind(this._handler)( + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectCriteriaTimestr_result({success: result}); + output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectCriteriaTimestr_result(err); + output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectCriteriaTimestr(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectCclTime (seqid, input, output) { + const args = new ConcourseService_selectCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectCclTime.length === 5) { + Promise.resolve(this._handler.selectCclTime.bind(this._handler)( + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectCclTime_result({success: result}); + output.writeMessageBegin("selectCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectCclTime_result(err); + output.writeMessageBegin("selectCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectCclTime(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectCclTimestr (seqid, input, output) { + const args = new ConcourseService_selectCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectCclTimestr.length === 5) { + Promise.resolve(this._handler.selectCclTimestr.bind(this._handler)( + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectCclTimestr_result({success: result}); + output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectCclTimestr_result(err); + output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectCclTimestr(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyCriteria (seqid, input, output) { + const args = new ConcourseService_selectKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyCriteria.length === 5) { + Promise.resolve(this._handler.selectKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyCriteria_result({success: result}); + output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyCriteria_result(err); + output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyCcl (seqid, input, output) { + const args = new ConcourseService_selectKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyCcl.length === 5) { + Promise.resolve(this._handler.selectKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyCcl_result({success: result}); + output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyCcl_result(err); + output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_selectKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.selectKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyCriteriaTime_result(err); + output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.selectKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyCriteriaTimestr_result(err); + output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyCclTime (seqid, input, output) { + const args = new ConcourseService_selectKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyCclTime.length === 6) { + Promise.resolve(this._handler.selectKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyCclTime_result({success: result}); + output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyCclTime_result(err); + output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.selectKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeyCclTimestr_result({success: result}); + output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeyCclTimestr_result(err); + output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysCriteria (seqid, input, output) { + const args = new ConcourseService_selectKeysCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysCriteria.length === 5) { + Promise.resolve(this._handler.selectKeysCriteria.bind(this._handler)( + args.keys, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysCriteria_result({success: result}); + output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysCriteria_result(err); + output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysCriteria(args.keys, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysCcl (seqid, input, output) { + const args = new ConcourseService_selectKeysCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysCcl.length === 5) { + Promise.resolve(this._handler.selectKeysCcl.bind(this._handler)( + args.keys, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysCcl_result({success: result}); + output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysCcl_result(err); + output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysCcl(args.keys, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysCriteriaTime (seqid, input, output) { + const args = new ConcourseService_selectKeysCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysCriteriaTime.length === 6) { + Promise.resolve(this._handler.selectKeysCriteriaTime.bind(this._handler)( + args.keys, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysCriteriaTime_result({success: result}); + output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysCriteriaTime_result(err); + output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysCriteriaTime(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeysCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.selectKeysCriteriaTimestr.bind(this._handler)( + args.keys, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysCriteriaTimestr_result({success: result}); + output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysCriteriaTimestr_result(err); + output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysCriteriaTimestr(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysCclTime (seqid, input, output) { + const args = new ConcourseService_selectKeysCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysCclTime.length === 6) { + Promise.resolve(this._handler.selectKeysCclTime.bind(this._handler)( + args.keys, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysCclTime_result({success: result}); + output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysCclTime_result(err); + output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysCclTime(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_selectKeysCclTimestr (seqid, input, output) { + const args = new ConcourseService_selectKeysCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.selectKeysCclTimestr.length === 6) { + Promise.resolve(this._handler.selectKeysCclTimestr.bind(this._handler)( + args.keys, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_selectKeysCclTimestr_result({success: result}); + output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_selectKeysCclTimestr_result(err); + output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.selectKeysCclTimestr(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_selectKeysCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyRecord (seqid, input, output) { + const args = new ConcourseService_getKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyRecord.length === 5) { + Promise.resolve(this._handler.getKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyRecord_result({success: result}); + output.writeMessageBegin("getKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyRecord_result(err); + output.writeMessageBegin("getKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_getKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyRecordTime.length === 6) { + Promise.resolve(this._handler.getKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyRecordTime_result({success: result}); + output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyRecordTime_result(err); + output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_getKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.getKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyRecordTimestr_result(err); + output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysRecord (seqid, input, output) { + const args = new ConcourseService_getKeysRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysRecord.length === 5) { + Promise.resolve(this._handler.getKeysRecord.bind(this._handler)( + args.keys, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysRecord_result({success: result}); + output.writeMessageBegin("getKeysRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysRecord_result(err); + output.writeMessageBegin("getKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysRecordTime (seqid, input, output) { + const args = new ConcourseService_getKeysRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysRecordTime.length === 6) { + Promise.resolve(this._handler.getKeysRecordTime.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysRecordTime_result({success: result}); + output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysRecordTime_result(err); + output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysRecordTimestr (seqid, input, output) { + const args = new ConcourseService_getKeysRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysRecordTimestr.length === 6) { + Promise.resolve(this._handler.getKeysRecordTimestr.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysRecordTimestr_result({success: result}); + output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysRecordTimestr_result(err); + output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysRecords (seqid, input, output) { + const args = new ConcourseService_getKeysRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysRecords.length === 5) { + Promise.resolve(this._handler.getKeysRecords.bind(this._handler)( + args.keys, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysRecords_result({success: result}); + output.writeMessageBegin("getKeysRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysRecords_result(err); + output.writeMessageBegin("getKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyRecords (seqid, input, output) { + const args = new ConcourseService_getKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyRecords.length === 5) { + Promise.resolve(this._handler.getKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyRecords_result({success: result}); + output.writeMessageBegin("getKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyRecords_result(err); + output.writeMessageBegin("getKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_getKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.getKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyRecordsTime_result({success: result}); + output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyRecordsTime_result(err); + output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_getKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.getKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyRecordsTimestr_result(err); + output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysRecordsTime (seqid, input, output) { + const args = new ConcourseService_getKeysRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysRecordsTime.length === 6) { + Promise.resolve(this._handler.getKeysRecordsTime.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysRecordsTime_result({success: result}); + output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysRecordsTime_result(err); + output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_getKeysRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysRecordsTimestr.length === 6) { + Promise.resolve(this._handler.getKeysRecordsTimestr.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysRecordsTimestr_result({success: result}); + output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysRecordsTimestr_result(err); + output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyCriteria (seqid, input, output) { + const args = new ConcourseService_getKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyCriteria.length === 5) { + Promise.resolve(this._handler.getKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyCriteria_result({success: result}); + output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyCriteria_result(err); + output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getCriteria (seqid, input, output) { + const args = new ConcourseService_getCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getCriteria.length === 4) { + Promise.resolve(this._handler.getCriteria.bind(this._handler)( + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getCriteria_result({success: result}); + output.writeMessageBegin("getCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getCriteria_result(err); + output.writeMessageBegin("getCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getCriteria(args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getCcl (seqid, input, output) { + const args = new ConcourseService_getCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getCcl.length === 4) { + Promise.resolve(this._handler.getCcl.bind(this._handler)( + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getCcl_result({success: result}); + output.writeMessageBegin("getCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getCcl_result(err); + output.writeMessageBegin("getCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getCcl(args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getCriteriaTime (seqid, input, output) { + const args = new ConcourseService_getCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getCriteriaTime.length === 5) { + Promise.resolve(this._handler.getCriteriaTime.bind(this._handler)( + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getCriteriaTime_result({success: result}); + output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getCriteriaTime_result(err); + output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getCriteriaTime(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_getCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getCriteriaTimestr.length === 5) { + Promise.resolve(this._handler.getCriteriaTimestr.bind(this._handler)( + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getCriteriaTimestr_result({success: result}); + output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getCriteriaTimestr_result(err); + output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getCriteriaTimestr(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getCclTime (seqid, input, output) { + const args = new ConcourseService_getCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getCclTime.length === 5) { + Promise.resolve(this._handler.getCclTime.bind(this._handler)( + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getCclTime_result({success: result}); + output.writeMessageBegin("getCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getCclTime_result(err); + output.writeMessageBegin("getCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getCclTime(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getCclTimestr (seqid, input, output) { + const args = new ConcourseService_getCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getCclTimestr.length === 5) { + Promise.resolve(this._handler.getCclTimestr.bind(this._handler)( + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getCclTimestr_result({success: result}); + output.writeMessageBegin("getCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getCclTimestr_result(err); + output.writeMessageBegin("getCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getCclTimestr(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyCcl (seqid, input, output) { + const args = new ConcourseService_getKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyCcl.length === 5) { + Promise.resolve(this._handler.getKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyCcl_result({success: result}); + output.writeMessageBegin("getKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyCcl_result(err); + output.writeMessageBegin("getKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_getKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.getKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyCriteriaTime_result(err); + output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_getKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.getKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyCriteriaTimestr_result(err); + output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyCclTime (seqid, input, output) { + const args = new ConcourseService_getKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyCclTime.length === 6) { + Promise.resolve(this._handler.getKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyCclTime_result({success: result}); + output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyCclTime_result(err); + output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_getKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.getKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeyCclTimestr_result({success: result}); + output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeyCclTimestr_result(err); + output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysCriteria (seqid, input, output) { + const args = new ConcourseService_getKeysCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysCriteria.length === 5) { + Promise.resolve(this._handler.getKeysCriteria.bind(this._handler)( + args.keys, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysCriteria_result({success: result}); + output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysCriteria_result(err); + output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysCriteria(args.keys, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysCcl (seqid, input, output) { + const args = new ConcourseService_getKeysCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysCcl.length === 5) { + Promise.resolve(this._handler.getKeysCcl.bind(this._handler)( + args.keys, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysCcl_result({success: result}); + output.writeMessageBegin("getKeysCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysCcl_result(err); + output.writeMessageBegin("getKeysCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysCcl(args.keys, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysCriteriaTime (seqid, input, output) { + const args = new ConcourseService_getKeysCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysCriteriaTime.length === 6) { + Promise.resolve(this._handler.getKeysCriteriaTime.bind(this._handler)( + args.keys, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysCriteriaTime_result({success: result}); + output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysCriteriaTime_result(err); + output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysCriteriaTime(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_getKeysCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.getKeysCriteriaTimestr.bind(this._handler)( + args.keys, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysCriteriaTimestr_result({success: result}); + output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysCriteriaTimestr_result(err); + output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysCriteriaTimestr(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysCclTime (seqid, input, output) { + const args = new ConcourseService_getKeysCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysCclTime.length === 6) { + Promise.resolve(this._handler.getKeysCclTime.bind(this._handler)( + args.keys, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysCclTime_result({success: result}); + output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysCclTime_result(err); + output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysCclTime(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getKeysCclTimestr (seqid, input, output) { + const args = new ConcourseService_getKeysCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getKeysCclTimestr.length === 6) { + Promise.resolve(this._handler.getKeysCclTimestr.bind(this._handler)( + args.keys, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getKeysCclTimestr_result({success: result}); + output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getKeysCclTimestr_result(err); + output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getKeysCclTimestr(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getKeysCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_verifyKeyValueRecord (seqid, input, output) { + const args = new ConcourseService_verifyKeyValueRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.verifyKeyValueRecord.length === 6) { + Promise.resolve(this._handler.verifyKeyValueRecord.bind(this._handler)( + args.key, + args.value, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_verifyKeyValueRecord_result({success: result}); + output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_verifyKeyValueRecord_result(err); + output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.verifyKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_verifyKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_verifyKeyValueRecordTime (seqid, input, output) { + const args = new ConcourseService_verifyKeyValueRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.verifyKeyValueRecordTime.length === 7) { + Promise.resolve(this._handler.verifyKeyValueRecordTime.bind(this._handler)( + args.key, + args.value, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_verifyKeyValueRecordTime_result({success: result}); + output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_verifyKeyValueRecordTime_result(err); + output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.verifyKeyValueRecordTime(args.key, args.value, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_verifyKeyValueRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_verifyKeyValueRecordTimestr (seqid, input, output) { + const args = new ConcourseService_verifyKeyValueRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.verifyKeyValueRecordTimestr.length === 7) { + Promise.resolve(this._handler.verifyKeyValueRecordTimestr.bind(this._handler)( + args.key, + args.value, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_verifyKeyValueRecordTimestr_result({success: result}); + output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_verifyKeyValueRecordTimestr_result(err); + output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.verifyKeyValueRecordTimestr(args.key, args.value, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_verifyKeyValueRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_jsonifyRecords (seqid, input, output) { + const args = new ConcourseService_jsonifyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.jsonifyRecords.length === 5) { + Promise.resolve(this._handler.jsonifyRecords.bind(this._handler)( + args.records, + args.identifier, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_jsonifyRecords_result({success: result}); + output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_jsonifyRecords_result(err); + output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.jsonifyRecords(args.records, args.identifier, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_jsonifyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_jsonifyRecordsTime (seqid, input, output) { + const args = new ConcourseService_jsonifyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.jsonifyRecordsTime.length === 6) { + Promise.resolve(this._handler.jsonifyRecordsTime.bind(this._handler)( + args.records, + args.timestamp, + args.identifier, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_jsonifyRecordsTime_result({success: result}); + output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_jsonifyRecordsTime_result(err); + output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.jsonifyRecordsTime(args.records, args.timestamp, args.identifier, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_jsonifyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_jsonifyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_jsonifyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.jsonifyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.jsonifyRecordsTimestr.bind(this._handler)( + args.records, + args.timestamp, + args.identifier, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_jsonifyRecordsTimestr_result({success: result}); + output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_jsonifyRecordsTimestr_result(err); + output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.jsonifyRecordsTimestr(args.records, args.timestamp, args.identifier, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_jsonifyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findCriteria (seqid, input, output) { + const args = new ConcourseService_findCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findCriteria.length === 4) { + Promise.resolve(this._handler.findCriteria.bind(this._handler)( + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findCriteria_result({success: result}); + output.writeMessageBegin("findCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findCriteria_result(err); + output.writeMessageBegin("findCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findCriteria(args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findCcl (seqid, input, output) { + const args = new ConcourseService_findCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findCcl.length === 4) { + Promise.resolve(this._handler.findCcl.bind(this._handler)( + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findCcl_result({success: result}); + output.writeMessageBegin("findCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findCcl_result(err); + output.writeMessageBegin("findCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findCcl(args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findKeyOperatorValues (seqid, input, output) { + const args = new ConcourseService_findKeyOperatorValues_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findKeyOperatorValues.length === 6) { + Promise.resolve(this._handler.findKeyOperatorValues.bind(this._handler)( + args.key, + args.operator, + args.values, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findKeyOperatorValues_result({success: result}); + output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findKeyOperatorValues_result(err); + output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findKeyOperatorValues(args.key, args.operator, args.values, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findKeyOperatorValues_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findKeyOperatorValuesTime (seqid, input, output) { + const args = new ConcourseService_findKeyOperatorValuesTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findKeyOperatorValuesTime.length === 7) { + Promise.resolve(this._handler.findKeyOperatorValuesTime.bind(this._handler)( + args.key, + args.operator, + args.values, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findKeyOperatorValuesTime_result({success: result}); + output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findKeyOperatorValuesTime_result(err); + output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findKeyOperatorValuesTime(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findKeyOperatorValuesTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findKeyOperatorValuesTimestr (seqid, input, output) { + const args = new ConcourseService_findKeyOperatorValuesTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findKeyOperatorValuesTimestr.length === 7) { + Promise.resolve(this._handler.findKeyOperatorValuesTimestr.bind(this._handler)( + args.key, + args.operator, + args.values, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findKeyOperatorValuesTimestr_result({success: result}); + output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findKeyOperatorValuesTimestr_result(err); + output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findKeyOperatorValuesTimestr(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findKeyOperatorValuesTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findKeyOperatorstrValues (seqid, input, output) { + const args = new ConcourseService_findKeyOperatorstrValues_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findKeyOperatorstrValues.length === 6) { + Promise.resolve(this._handler.findKeyOperatorstrValues.bind(this._handler)( + args.key, + args.operator, + args.values, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findKeyOperatorstrValues_result({success: result}); + output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findKeyOperatorstrValues_result(err); + output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findKeyOperatorstrValues(args.key, args.operator, args.values, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findKeyOperatorstrValues_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findKeyOperatorstrValuesTime (seqid, input, output) { + const args = new ConcourseService_findKeyOperatorstrValuesTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findKeyOperatorstrValuesTime.length === 7) { + Promise.resolve(this._handler.findKeyOperatorstrValuesTime.bind(this._handler)( + args.key, + args.operator, + args.values, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findKeyOperatorstrValuesTime_result({success: result}); + output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findKeyOperatorstrValuesTime_result(err); + output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findKeyOperatorstrValuesTime(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findKeyOperatorstrValuesTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findKeyOperatorstrValuesTimestr (seqid, input, output) { + const args = new ConcourseService_findKeyOperatorstrValuesTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findKeyOperatorstrValuesTimestr.length === 7) { + Promise.resolve(this._handler.findKeyOperatorstrValuesTimestr.bind(this._handler)( + args.key, + args.operator, + args.values, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findKeyOperatorstrValuesTimestr_result({success: result}); + output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findKeyOperatorstrValuesTimestr_result(err); + output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findKeyOperatorstrValuesTimestr(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findKeyOperatorstrValuesTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_search (seqid, input, output) { + const args = new ConcourseService_search_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.search.length === 5) { + Promise.resolve(this._handler.search.bind(this._handler)( + args.key, + args.query, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_search_result({success: result}); + output.writeMessageBegin("search", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_search_result(err); + output.writeMessageBegin("search", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("search", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.search(args.key, args.query, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_search_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("search", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("search", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeysRecordsTime (seqid, input, output) { + const args = new ConcourseService_revertKeysRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeysRecordsTime.length === 6) { + Promise.resolve(this._handler.revertKeysRecordsTime.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeysRecordsTime_result({success: result}); + output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeysRecordsTime_result(err); + output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeysRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_revertKeysRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeysRecordsTimestr.length === 6) { + Promise.resolve(this._handler.revertKeysRecordsTimestr.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeysRecordsTimestr_result({success: result}); + output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeysRecordsTimestr_result(err); + output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeysRecordTime (seqid, input, output) { + const args = new ConcourseService_revertKeysRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeysRecordTime.length === 6) { + Promise.resolve(this._handler.revertKeysRecordTime.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeysRecordTime_result({success: result}); + output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeysRecordTime_result(err); + output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeysRecordTimestr (seqid, input, output) { + const args = new ConcourseService_revertKeysRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeysRecordTimestr.length === 6) { + Promise.resolve(this._handler.revertKeysRecordTimestr.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeysRecordTimestr_result({success: result}); + output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeysRecordTimestr_result(err); + output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_revertKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.revertKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeyRecordsTime_result({success: result}); + output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeyRecordsTime_result(err); + output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_revertKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.revertKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeyRecordsTimestr_result(err); + output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_revertKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeyRecordTime.length === 6) { + Promise.resolve(this._handler.revertKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeyRecordTime_result({success: result}); + output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeyRecordTime_result(err); + output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_revertKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_revertKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.revertKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.revertKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_revertKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_revertKeyRecordTimestr_result(err); + output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.revertKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_revertKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_pingRecords (seqid, input, output) { + const args = new ConcourseService_pingRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.pingRecords.length === 4) { + Promise.resolve(this._handler.pingRecords.bind(this._handler)( + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_pingRecords_result({success: result}); + output.writeMessageBegin("pingRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_pingRecords_result(err); + output.writeMessageBegin("pingRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("pingRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.pingRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_pingRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("pingRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("pingRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_pingRecord (seqid, input, output) { + const args = new ConcourseService_pingRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.pingRecord.length === 4) { + Promise.resolve(this._handler.pingRecord.bind(this._handler)( + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_pingRecord_result({success: result}); + output.writeMessageBegin("pingRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_pingRecord_result(err); + output.writeMessageBegin("pingRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("pingRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.pingRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_pingRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("pingRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("pingRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_verifyAndSwap (seqid, input, output) { + const args = new ConcourseService_verifyAndSwap_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.verifyAndSwap.length === 7) { + Promise.resolve(this._handler.verifyAndSwap.bind(this._handler)( + args.key, + args.expected, + args.record, + args.replacement, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_verifyAndSwap_result({success: result}); + output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_verifyAndSwap_result(err); + output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.verifyAndSwap(args.key, args.expected, args.record, args.replacement, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_verifyAndSwap_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_verifyOrSet (seqid, input, output) { + const args = new ConcourseService_verifyOrSet_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.verifyOrSet.length === 6) { + Promise.resolve(this._handler.verifyOrSet.bind(this._handler)( + args.key, + args.value, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_verifyOrSet_result({success: result}); + output.writeMessageBegin("verifyOrSet", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_verifyOrSet_result(err); + output.writeMessageBegin("verifyOrSet", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyOrSet", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.verifyOrSet(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_verifyOrSet_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("verifyOrSet", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("verifyOrSet", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findOrAddKeyValue (seqid, input, output) { + const args = new ConcourseService_findOrAddKeyValue_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findOrAddKeyValue.length === 5) { + Promise.resolve(this._handler.findOrAddKeyValue.bind(this._handler)( + args.key, + args.value, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findOrAddKeyValue_result({success: result}); + output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findOrAddKeyValue_result(err); + output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findOrAddKeyValue(args.key, args.value, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findOrAddKeyValue_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findOrInsertCriteriaJson (seqid, input, output) { + const args = new ConcourseService_findOrInsertCriteriaJson_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findOrInsertCriteriaJson.length === 5) { + Promise.resolve(this._handler.findOrInsertCriteriaJson.bind(this._handler)( + args.criteria, + args.json, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findOrInsertCriteriaJson_result({success: result}); + output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findOrInsertCriteriaJson_result(err); + output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findOrInsertCriteriaJson(args.criteria, args.json, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findOrInsertCriteriaJson_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_findOrInsertCclJson (seqid, input, output) { + const args = new ConcourseService_findOrInsertCclJson_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.findOrInsertCclJson.length === 5) { + Promise.resolve(this._handler.findOrInsertCclJson.bind(this._handler)( + args.ccl, + args.json, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_findOrInsertCclJson_result({success: result}); + output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_findOrInsertCclJson_result(err); + output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.findOrInsertCclJson(args.ccl, args.json, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_findOrInsertCclJson_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyRecord (seqid, input, output) { + const args = new ConcourseService_sumKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyRecord.length === 5) { + Promise.resolve(this._handler.sumKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyRecord_result({success: result}); + output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyRecord_result(err); + output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_sumKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyRecordTime.length === 6) { + Promise.resolve(this._handler.sumKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyRecordTime_result({success: result}); + output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyRecordTime_result(err); + output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_sumKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.sumKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyRecordTimestr_result(err); + output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyRecords (seqid, input, output) { + const args = new ConcourseService_sumKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyRecords.length === 5) { + Promise.resolve(this._handler.sumKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyRecords_result({success: result}); + output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyRecords_result(err); + output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_sumKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.sumKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyRecordsTime_result({success: result}); + output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyRecordsTime_result(err); + output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_sumKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.sumKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyRecordsTimestr_result(err); + output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKey (seqid, input, output) { + const args = new ConcourseService_sumKey_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKey.length === 4) { + Promise.resolve(this._handler.sumKey.bind(this._handler)( + args.key, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKey_result({success: result}); + output.writeMessageBegin("sumKey", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKey_result(err); + output.writeMessageBegin("sumKey", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKey", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKey", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKey", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyTime (seqid, input, output) { + const args = new ConcourseService_sumKeyTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyTime.length === 5) { + Promise.resolve(this._handler.sumKeyTime.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyTime_result({success: result}); + output.writeMessageBegin("sumKeyTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyTime_result(err); + output.writeMessageBegin("sumKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyTimestr (seqid, input, output) { + const args = new ConcourseService_sumKeyTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyTimestr.length === 5) { + Promise.resolve(this._handler.sumKeyTimestr.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyTimestr_result({success: result}); + output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyTimestr_result(err); + output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyCriteria (seqid, input, output) { + const args = new ConcourseService_sumKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyCriteria.length === 5) { + Promise.resolve(this._handler.sumKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyCriteria_result({success: result}); + output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyCriteria_result(err); + output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_sumKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.sumKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyCriteriaTime_result(err); + output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_sumKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.sumKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyCriteriaTimestr_result(err); + output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyCcl (seqid, input, output) { + const args = new ConcourseService_sumKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyCcl.length === 5) { + Promise.resolve(this._handler.sumKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyCcl_result({success: result}); + output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyCcl_result(err); + output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyCclTime (seqid, input, output) { + const args = new ConcourseService_sumKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyCclTime.length === 6) { + Promise.resolve(this._handler.sumKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyCclTime_result({success: result}); + output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyCclTime_result(err); + output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_sumKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_sumKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.sumKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.sumKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_sumKeyCclTimestr_result({success: result}); + output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_sumKeyCclTimestr_result(err); + output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.sumKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_sumKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyRecord (seqid, input, output) { + const args = new ConcourseService_averageKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyRecord.length === 5) { + Promise.resolve(this._handler.averageKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyRecord_result({success: result}); + output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyRecord_result(err); + output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_averageKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyRecordTime.length === 6) { + Promise.resolve(this._handler.averageKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyRecordTime_result({success: result}); + output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyRecordTime_result(err); + output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_averageKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.averageKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyRecordTimestr_result(err); + output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyRecords (seqid, input, output) { + const args = new ConcourseService_averageKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyRecords.length === 5) { + Promise.resolve(this._handler.averageKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyRecords_result({success: result}); + output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyRecords_result(err); + output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_averageKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.averageKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyRecordsTime_result({success: result}); + output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyRecordsTime_result(err); + output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_averageKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.averageKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyRecordsTimestr_result(err); + output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKey (seqid, input, output) { + const args = new ConcourseService_averageKey_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKey.length === 4) { + Promise.resolve(this._handler.averageKey.bind(this._handler)( + args.key, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKey_result({success: result}); + output.writeMessageBegin("averageKey", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKey_result(err); + output.writeMessageBegin("averageKey", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKey", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKey", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKey", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyTime (seqid, input, output) { + const args = new ConcourseService_averageKeyTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyTime.length === 5) { + Promise.resolve(this._handler.averageKeyTime.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyTime_result({success: result}); + output.writeMessageBegin("averageKeyTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyTime_result(err); + output.writeMessageBegin("averageKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyTimestr (seqid, input, output) { + const args = new ConcourseService_averageKeyTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyTimestr.length === 5) { + Promise.resolve(this._handler.averageKeyTimestr.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyTimestr_result({success: result}); + output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyTimestr_result(err); + output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyCriteria (seqid, input, output) { + const args = new ConcourseService_averageKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyCriteria.length === 5) { + Promise.resolve(this._handler.averageKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyCriteria_result({success: result}); + output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyCriteria_result(err); + output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_averageKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.averageKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyCriteriaTime_result(err); + output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_averageKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.averageKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyCriteriaTimestr_result(err); + output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyCcl (seqid, input, output) { + const args = new ConcourseService_averageKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyCcl.length === 5) { + Promise.resolve(this._handler.averageKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyCcl_result({success: result}); + output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyCcl_result(err); + output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyCclTime (seqid, input, output) { + const args = new ConcourseService_averageKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyCclTime.length === 6) { + Promise.resolve(this._handler.averageKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyCclTime_result({success: result}); + output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyCclTime_result(err); + output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_averageKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_averageKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.averageKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.averageKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_averageKeyCclTimestr_result({success: result}); + output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_averageKeyCclTimestr_result(err); + output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.averageKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_averageKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyRecord (seqid, input, output) { + const args = new ConcourseService_countKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyRecord.length === 5) { + Promise.resolve(this._handler.countKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyRecord_result({success: result}); + output.writeMessageBegin("countKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyRecord_result(err); + output.writeMessageBegin("countKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_countKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyRecordTime.length === 6) { + Promise.resolve(this._handler.countKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyRecordTime_result({success: result}); + output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyRecordTime_result(err); + output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_countKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.countKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyRecordTimestr_result(err); + output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyRecords (seqid, input, output) { + const args = new ConcourseService_countKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyRecords.length === 5) { + Promise.resolve(this._handler.countKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyRecords_result({success: result}); + output.writeMessageBegin("countKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyRecords_result(err); + output.writeMessageBegin("countKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_countKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.countKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyRecordsTime_result({success: result}); + output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyRecordsTime_result(err); + output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_countKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.countKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyRecordsTimestr_result(err); + output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKey (seqid, input, output) { + const args = new ConcourseService_countKey_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKey.length === 4) { + Promise.resolve(this._handler.countKey.bind(this._handler)( + args.key, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKey_result({success: result}); + output.writeMessageBegin("countKey", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKey_result(err); + output.writeMessageBegin("countKey", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKey", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKey", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKey", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyTime (seqid, input, output) { + const args = new ConcourseService_countKeyTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyTime.length === 5) { + Promise.resolve(this._handler.countKeyTime.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyTime_result({success: result}); + output.writeMessageBegin("countKeyTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyTime_result(err); + output.writeMessageBegin("countKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyTimestr (seqid, input, output) { + const args = new ConcourseService_countKeyTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyTimestr.length === 5) { + Promise.resolve(this._handler.countKeyTimestr.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyTimestr_result({success: result}); + output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyTimestr_result(err); + output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyCriteria (seqid, input, output) { + const args = new ConcourseService_countKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyCriteria.length === 5) { + Promise.resolve(this._handler.countKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyCriteria_result({success: result}); + output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyCriteria_result(err); + output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_countKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.countKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyCriteriaTime_result(err); + output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_countKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.countKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyCriteriaTimestr_result(err); + output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyCcl (seqid, input, output) { + const args = new ConcourseService_countKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyCcl.length === 5) { + Promise.resolve(this._handler.countKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyCcl_result({success: result}); + output.writeMessageBegin("countKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyCcl_result(err); + output.writeMessageBegin("countKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyCclTime (seqid, input, output) { + const args = new ConcourseService_countKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyCclTime.length === 6) { + Promise.resolve(this._handler.countKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyCclTime_result({success: result}); + output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyCclTime_result(err); + output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_countKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_countKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.countKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.countKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_countKeyCclTimestr_result({success: result}); + output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_countKeyCclTimestr_result(err); + output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.countKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_countKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyRecord (seqid, input, output) { + const args = new ConcourseService_maxKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyRecord.length === 5) { + Promise.resolve(this._handler.maxKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyRecord_result({success: result}); + output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyRecord_result(err); + output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_maxKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyRecordTime.length === 6) { + Promise.resolve(this._handler.maxKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyRecordTime_result({success: result}); + output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyRecordTime_result(err); + output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_maxKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.maxKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyRecordTimestr_result(err); + output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyRecords (seqid, input, output) { + const args = new ConcourseService_maxKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyRecords.length === 5) { + Promise.resolve(this._handler.maxKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyRecords_result({success: result}); + output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyRecords_result(err); + output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_maxKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.maxKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyRecordsTime_result({success: result}); + output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyRecordsTime_result(err); + output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_maxKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.maxKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyRecordsTimestr_result(err); + output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyCriteria (seqid, input, output) { + const args = new ConcourseService_maxKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyCriteria.length === 5) { + Promise.resolve(this._handler.maxKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyCriteria_result({success: result}); + output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyCriteria_result(err); + output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_maxKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.maxKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyCriteriaTime_result(err); + output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_maxKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.maxKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyCriteriaTimestr_result(err); + output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyCcl (seqid, input, output) { + const args = new ConcourseService_maxKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyCcl.length === 5) { + Promise.resolve(this._handler.maxKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyCcl_result({success: result}); + output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyCcl_result(err); + output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyCclTime (seqid, input, output) { + const args = new ConcourseService_maxKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyCclTime.length === 6) { + Promise.resolve(this._handler.maxKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyCclTime_result({success: result}); + output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyCclTime_result(err); + output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_maxKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.maxKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyCclTimestr_result({success: result}); + output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyCclTimestr_result(err); + output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKey (seqid, input, output) { + const args = new ConcourseService_maxKey_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKey.length === 4) { + Promise.resolve(this._handler.maxKey.bind(this._handler)( + args.key, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKey_result({success: result}); + output.writeMessageBegin("maxKey", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKey_result(err); + output.writeMessageBegin("maxKey", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKey", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKey", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKey", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyTime (seqid, input, output) { + const args = new ConcourseService_maxKeyTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyTime.length === 5) { + Promise.resolve(this._handler.maxKeyTime.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyTime_result({success: result}); + output.writeMessageBegin("maxKeyTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyTime_result(err); + output.writeMessageBegin("maxKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_maxKeyTimestr (seqid, input, output) { + const args = new ConcourseService_maxKeyTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.maxKeyTimestr.length === 5) { + Promise.resolve(this._handler.maxKeyTimestr.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_maxKeyTimestr_result({success: result}); + output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_maxKeyTimestr_result(err); + output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.maxKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_maxKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyRecord (seqid, input, output) { + const args = new ConcourseService_minKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyRecord.length === 5) { + Promise.resolve(this._handler.minKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyRecord_result({success: result}); + output.writeMessageBegin("minKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyRecord_result(err); + output.writeMessageBegin("minKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_minKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyRecordTime.length === 6) { + Promise.resolve(this._handler.minKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyRecordTime_result({success: result}); + output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyRecordTime_result(err); + output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_minKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.minKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyRecordTimestr_result(err); + output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKey (seqid, input, output) { + const args = new ConcourseService_minKey_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKey.length === 4) { + Promise.resolve(this._handler.minKey.bind(this._handler)( + args.key, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKey_result({success: result}); + output.writeMessageBegin("minKey", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKey_result(err); + output.writeMessageBegin("minKey", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKey", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKey", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKey", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_minKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.minKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyRecordsTime_result({success: result}); + output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyRecordsTime_result(err); + output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_minKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.minKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyRecordsTimestr_result(err); + output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyCriteria (seqid, input, output) { + const args = new ConcourseService_minKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyCriteria.length === 5) { + Promise.resolve(this._handler.minKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyCriteria_result({success: result}); + output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyCriteria_result(err); + output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_minKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.minKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyCriteriaTime_result(err); + output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_minKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.minKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyCriteriaTimestr_result(err); + output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyCcl (seqid, input, output) { + const args = new ConcourseService_minKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyCcl.length === 5) { + Promise.resolve(this._handler.minKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyCcl_result({success: result}); + output.writeMessageBegin("minKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyCcl_result(err); + output.writeMessageBegin("minKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyCclTime (seqid, input, output) { + const args = new ConcourseService_minKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyCclTime.length === 6) { + Promise.resolve(this._handler.minKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyCclTime_result({success: result}); + output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyCclTime_result(err); + output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_minKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.minKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyCclTimestr_result({success: result}); + output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyCclTimestr_result(err); + output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyTime (seqid, input, output) { + const args = new ConcourseService_minKeyTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyTime.length === 5) { + Promise.resolve(this._handler.minKeyTime.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyTime_result({success: result}); + output.writeMessageBegin("minKeyTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyTime_result(err); + output.writeMessageBegin("minKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyTimestr (seqid, input, output) { + const args = new ConcourseService_minKeyTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyTimestr.length === 5) { + Promise.resolve(this._handler.minKeyTimestr.bind(this._handler)( + args.key, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyTimestr_result({success: result}); + output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyTimestr_result(err); + output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_minKeyRecords (seqid, input, output) { + const args = new ConcourseService_minKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.minKeyRecords.length === 5) { + Promise.resolve(this._handler.minKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_minKeyRecords_result({success: result}); + output.writeMessageBegin("minKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_minKeyRecords_result(err); + output.writeMessageBegin("minKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.minKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_minKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("minKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("minKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyRecord (seqid, input, output) { + const args = new ConcourseService_navigateKeyRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyRecord.length === 5) { + Promise.resolve(this._handler.navigateKeyRecord.bind(this._handler)( + args.key, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyRecord_result({success: result}); + output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyRecord_result(err); + output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyRecordTime (seqid, input, output) { + const args = new ConcourseService_navigateKeyRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyRecordTime.length === 6) { + Promise.resolve(this._handler.navigateKeyRecordTime.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyRecordTime_result({success: result}); + output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyRecordTime_result(err); + output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyRecordTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeyRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyRecordTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeyRecordTimestr.bind(this._handler)( + args.key, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyRecordTimestr_result({success: result}); + output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyRecordTimestr_result(err); + output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysRecord (seqid, input, output) { + const args = new ConcourseService_navigateKeysRecord_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysRecord.length === 5) { + Promise.resolve(this._handler.navigateKeysRecord.bind(this._handler)( + args.keys, + args.record, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysRecord_result({success: result}); + output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysRecord_result(err); + output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysRecordTime (seqid, input, output) { + const args = new ConcourseService_navigateKeysRecordTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysRecordTime.length === 6) { + Promise.resolve(this._handler.navigateKeysRecordTime.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysRecordTime_result({success: result}); + output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysRecordTime_result(err); + output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysRecordTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeysRecordTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysRecordTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeysRecordTimestr.bind(this._handler)( + args.keys, + args.record, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysRecordTimestr_result({success: result}); + output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysRecordTimestr_result(err); + output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysRecords (seqid, input, output) { + const args = new ConcourseService_navigateKeysRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysRecords.length === 5) { + Promise.resolve(this._handler.navigateKeysRecords.bind(this._handler)( + args.keys, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysRecords_result({success: result}); + output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysRecords_result(err); + output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyRecords (seqid, input, output) { + const args = new ConcourseService_navigateKeyRecords_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyRecords.length === 5) { + Promise.resolve(this._handler.navigateKeyRecords.bind(this._handler)( + args.key, + args.records, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyRecords_result({success: result}); + output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyRecords_result(err); + output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyRecordsTime (seqid, input, output) { + const args = new ConcourseService_navigateKeyRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyRecordsTime.length === 6) { + Promise.resolve(this._handler.navigateKeyRecordsTime.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyRecordsTime_result({success: result}); + output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyRecordsTime_result(err); + output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeyRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyRecordsTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeyRecordsTimestr.bind(this._handler)( + args.key, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyRecordsTimestr_result({success: result}); + output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyRecordsTimestr_result(err); + output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysRecordsTime (seqid, input, output) { + const args = new ConcourseService_navigateKeysRecordsTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysRecordsTime.length === 6) { + Promise.resolve(this._handler.navigateKeysRecordsTime.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysRecordsTime_result({success: result}); + output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysRecordsTime_result(err); + output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysRecordsTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeysRecordsTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysRecordsTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeysRecordsTimestr.bind(this._handler)( + args.keys, + args.records, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysRecordsTimestr_result({success: result}); + output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysRecordsTimestr_result(err); + output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyCcl (seqid, input, output) { + const args = new ConcourseService_navigateKeyCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyCcl.length === 5) { + Promise.resolve(this._handler.navigateKeyCcl.bind(this._handler)( + args.key, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyCcl_result({success: result}); + output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyCcl_result(err); + output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyCclTime (seqid, input, output) { + const args = new ConcourseService_navigateKeyCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyCclTime.length === 6) { + Promise.resolve(this._handler.navigateKeyCclTime.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyCclTime_result({success: result}); + output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyCclTime_result(err); + output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyCclTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeyCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyCclTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeyCclTimestr.bind(this._handler)( + args.key, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyCclTimestr_result({success: result}); + output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyCclTimestr_result(err); + output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysCcl (seqid, input, output) { + const args = new ConcourseService_navigateKeysCcl_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysCcl.length === 5) { + Promise.resolve(this._handler.navigateKeysCcl.bind(this._handler)( + args.keys, + args.ccl, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysCcl_result({success: result}); + output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysCcl_result(err); + output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysCcl(args.keys, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysCclTime (seqid, input, output) { + const args = new ConcourseService_navigateKeysCclTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysCclTime.length === 6) { + Promise.resolve(this._handler.navigateKeysCclTime.bind(this._handler)( + args.keys, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysCclTime_result({success: result}); + output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysCclTime_result(err); + output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysCclTime(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysCclTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeysCclTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysCclTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeysCclTimestr.bind(this._handler)( + args.keys, + args.ccl, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysCclTimestr_result({success: result}); + output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysCclTimestr_result(err); + output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysCclTimestr(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyCriteria (seqid, input, output) { + const args = new ConcourseService_navigateKeyCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyCriteria.length === 5) { + Promise.resolve(this._handler.navigateKeyCriteria.bind(this._handler)( + args.key, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyCriteria_result({success: result}); + output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyCriteria_result(err); + output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyCriteriaTime (seqid, input, output) { + const args = new ConcourseService_navigateKeyCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyCriteriaTime.length === 6) { + Promise.resolve(this._handler.navigateKeyCriteriaTime.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyCriteriaTime_result({success: result}); + output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyCriteriaTime_result(err); + output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeyCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeyCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeyCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeyCriteriaTimestr.bind(this._handler)( + args.key, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeyCriteriaTimestr_result({success: result}); + output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeyCriteriaTimestr_result(err); + output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysCriteria (seqid, input, output) { + const args = new ConcourseService_navigateKeysCriteria_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysCriteria.length === 5) { + Promise.resolve(this._handler.navigateKeysCriteria.bind(this._handler)( + args.keys, + args.criteria, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysCriteria_result({success: result}); + output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysCriteria_result(err); + output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysCriteria(args.keys, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysCriteriaTime (seqid, input, output) { + const args = new ConcourseService_navigateKeysCriteriaTime_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysCriteriaTime.length === 6) { + Promise.resolve(this._handler.navigateKeysCriteriaTime.bind(this._handler)( + args.keys, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysCriteriaTime_result({success: result}); + output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysCriteriaTime_result(err); + output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysCriteriaTime(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_navigateKeysCriteriaTimestr (seqid, input, output) { + const args = new ConcourseService_navigateKeysCriteriaTimestr_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.navigateKeysCriteriaTimestr.length === 6) { + Promise.resolve(this._handler.navigateKeysCriteriaTimestr.bind(this._handler)( + args.keys, + args.criteria, + args.timestamp, + args.creds, + args.transaction, + args.environment + )).then(result => { + const result_obj = new ConcourseService_navigateKeysCriteriaTimestr_result({success: result}); + output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_navigateKeysCriteriaTimestr_result(err); + output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.navigateKeysCriteriaTimestr(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_navigateKeysCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getServerEnvironment (seqid, input, output) { + const args = new ConcourseService_getServerEnvironment_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getServerEnvironment.length === 3) { + Promise.resolve(this._handler.getServerEnvironment.bind(this._handler)( + args.creds, + args.token, + args.environment + )).then(result => { + const result_obj = new ConcourseService_getServerEnvironment_result({success: result}); + output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getServerEnvironment_result(err); + output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getServerEnvironment(args.creds, args.token, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getServerEnvironment_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_getServerVersion (seqid, input, output) { + const args = new ConcourseService_getServerVersion_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.getServerVersion.length === 0) { + Promise.resolve(this._handler.getServerVersion.bind(this._handler)( + )).then(result => { + const result_obj = new ConcourseService_getServerVersion_result({success: result}); + output.writeMessageBegin("getServerVersion", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_getServerVersion_result(err); + output.writeMessageBegin("getServerVersion", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getServerVersion", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.getServerVersion((err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_getServerVersion_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("getServerVersion", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("getServerVersion", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_time (seqid, input, output) { + const args = new ConcourseService_time_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.time.length === 3) { + Promise.resolve(this._handler.time.bind(this._handler)( + args.creds, + args.token, + args.environment + )).then(result => { + const result_obj = new ConcourseService_time_result({success: result}); + output.writeMessageBegin("time", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_time_result(err); + output.writeMessageBegin("time", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("time", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.time(args.creds, args.token, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_time_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("time", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("time", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_timePhrase (seqid, input, output) { + const args = new ConcourseService_timePhrase_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.timePhrase.length === 4) { + Promise.resolve(this._handler.timePhrase.bind(this._handler)( + args.phrase, + args.creds, + args.token, + args.environment + )).then(result => { + const result_obj = new ConcourseService_timePhrase_result({success: result}); + output.writeMessageBegin("timePhrase", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result = new ConcourseService_timePhrase_result(err); + output.writeMessageBegin("timePhrase", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("timePhrase", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.timePhrase(args.phrase, args.creds, args.token, args.environment, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { + result_obj = new ConcourseService_timePhrase_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("timePhrase", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("timePhrase", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } + process_invokeManagement (seqid, input, output) { + const args = new ConcourseService_invokeManagement_args(); + args.read(input); + input.readMessageEnd(); + if (this._handler.invokeManagement.length === 3) { + Promise.resolve(this._handler.invokeManagement.bind(this._handler)( + args.method, + args.params, + args.creds + )).then(result => { + const result_obj = new ConcourseService_invokeManagement_result({success: result}); + output.writeMessageBegin("invokeManagement", Thrift.MessageType.REPLY, seqid); + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }).catch(err => { + let result; + if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.ManagementException) { + result = new ConcourseService_invokeManagement_result(err); + output.writeMessageBegin("invokeManagement", Thrift.MessageType.REPLY, seqid); + } else { + result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("invokeManagement", Thrift.MessageType.EXCEPTION, seqid); + } + result.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } else { + this._handler.invokeManagement(args.method, args.params, args.creds, (err, result) => { + let result_obj; + if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.ManagementException) { + result_obj = new ConcourseService_invokeManagement_result((err !== null || typeof err === 'undefined') ? err : {success: result}); + output.writeMessageBegin("invokeManagement", Thrift.MessageType.REPLY, seqid); + } else { + result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); + output.writeMessageBegin("invokeManagement", Thrift.MessageType.EXCEPTION, seqid); + } + result_obj.write(output); + output.writeMessageEnd(); + output.flush(); + }); + } + } +}; diff --git a/concourse-driver-node-js/src/thrift/complex_types.js b/concourse-driver-node-js/src/thrift/complex_types.js new file mode 100644 index 0000000000..bc051f2a38 --- /dev/null +++ b/concourse-driver-node-js/src/thrift/complex_types.js @@ -0,0 +1,241 @@ +// +// Autogenerated by Thrift Compiler (0.12.0) +// +// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING +// +"use strict"; + +const thrift = require('thrift'); +const Thrift = thrift.Thrift; + +const data_ttypes = require('./data_types'); + + +const ttypes = module.exports = {}; +ttypes.ComplexTObjectType = { + 'SCALAR' : 1, + 'MAP' : 2, + 'LIST' : 3, + 'SET' : 4, + 'TOBJECT' : 5, + 'TCRITERIA' : 6, + 'BINARY' : 7 +}; +const ComplexTObject = module.exports.ComplexTObject = class { + constructor(args) { + this.type = null; + this.tscalar = null; + this.tmap = null; + this.tlist = null; + this.tset = null; + this.tobject = null; + this.tcriteria = null; + this.tbinary = null; + if (args) { + if (args.type !== undefined && args.type !== null) { + this.type = args.type; + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field type is unset!'); + } + if (args.tscalar !== undefined && args.tscalar !== null) { + this.tscalar = new data_ttypes.TObject(args.tscalar); + } + if (args.tmap !== undefined && args.tmap !== null) { + this.tmap = Thrift.copyMap(args.tmap, [null]); + } + if (args.tlist !== undefined && args.tlist !== null) { + this.tlist = Thrift.copyList(args.tlist, [null]); + } + if (args.tset !== undefined && args.tset !== null) { + this.tset = Thrift.copyList(args.tset, [null]); + } + if (args.tobject !== undefined && args.tobject !== null) { + this.tobject = new data_ttypes.TObject(args.tobject); + } + if (args.tcriteria !== undefined && args.tcriteria !== null) { + this.tcriteria = new data_ttypes.TCriteria(args.tcriteria); + } + if (args.tbinary !== undefined && args.tbinary !== null) { + this.tbinary = args.tbinary; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I32) { + this.type = input.readI32(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRUCT) { + this.tscalar = new data_ttypes.TObject(); + this.tscalar.read(input); + } else { + input.skip(ftype); + } + break; + case 3: + if (ftype == Thrift.Type.MAP) { + this.tmap = {}; + const _rtmp31 = input.readMapBegin(); + const _size0 = _rtmp31.size || 0; + for (let _i2 = 0; _i2 < _size0; ++_i2) { + let key3 = null; + let val4 = null; + key3 = new ttypes.ComplexTObject(); + key3.read(input); + val4 = new ttypes.ComplexTObject(); + val4.read(input); + this.tmap[key3] = val4; + } + input.readMapEnd(); + } else { + input.skip(ftype); + } + break; + case 4: + if (ftype == Thrift.Type.LIST) { + this.tlist = []; + const _rtmp36 = input.readListBegin(); + const _size5 = _rtmp36.size || 0; + for (let _i7 = 0; _i7 < _size5; ++_i7) { + let elem8 = null; + elem8 = new ttypes.ComplexTObject(); + elem8.read(input); + this.tlist.push(elem8); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 5: + if (ftype == Thrift.Type.SET) { + this.tset = []; + const _rtmp310 = input.readSetBegin(); + const _size9 = _rtmp310.size || 0; + for (let _i11 = 0; _i11 < _size9; ++_i11) { + let elem12 = null; + elem12 = new ttypes.ComplexTObject(); + elem12.read(input); + this.tset.push(elem12); + } + input.readSetEnd(); + } else { + input.skip(ftype); + } + break; + case 6: + if (ftype == Thrift.Type.STRUCT) { + this.tobject = new data_ttypes.TObject(); + this.tobject.read(input); + } else { + input.skip(ftype); + } + break; + case 7: + if (ftype == Thrift.Type.STRUCT) { + this.tcriteria = new data_ttypes.TCriteria(); + this.tcriteria.read(input); + } else { + input.skip(ftype); + } + break; + case 8: + if (ftype == Thrift.Type.STRING) { + this.tbinary = input.readBinary(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ComplexTObject'); + if (this.type !== null && this.type !== undefined) { + output.writeFieldBegin('type', Thrift.Type.I32, 1); + output.writeI32(this.type); + output.writeFieldEnd(); + } + if (this.tscalar !== null && this.tscalar !== undefined) { + output.writeFieldBegin('tscalar', Thrift.Type.STRUCT, 2); + this.tscalar.write(output); + output.writeFieldEnd(); + } + if (this.tmap !== null && this.tmap !== undefined) { + output.writeFieldBegin('tmap', Thrift.Type.MAP, 3); + output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.STRUCT, Thrift.objectLength(this.tmap)); + for (let kiter13 in this.tmap) { + if (this.tmap.hasOwnProperty(kiter13)) { + let viter14 = this.tmap[kiter13]; + kiter13.write(output); + viter14.write(output); + } + } + output.writeMapEnd(); + output.writeFieldEnd(); + } + if (this.tlist !== null && this.tlist !== undefined) { + output.writeFieldBegin('tlist', Thrift.Type.LIST, 4); + output.writeListBegin(Thrift.Type.STRUCT, this.tlist.length); + for (let iter15 in this.tlist) { + if (this.tlist.hasOwnProperty(iter15)) { + iter15 = this.tlist[iter15]; + iter15.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + if (this.tset !== null && this.tset !== undefined) { + output.writeFieldBegin('tset', Thrift.Type.SET, 5); + output.writeSetBegin(Thrift.Type.STRUCT, this.tset.length); + for (let iter16 in this.tset) { + if (this.tset.hasOwnProperty(iter16)) { + iter16 = this.tset[iter16]; + iter16.write(output); + } + } + output.writeSetEnd(); + output.writeFieldEnd(); + } + if (this.tobject !== null && this.tobject !== undefined) { + output.writeFieldBegin('tobject', Thrift.Type.STRUCT, 6); + this.tobject.write(output); + output.writeFieldEnd(); + } + if (this.tcriteria !== null && this.tcriteria !== undefined) { + output.writeFieldBegin('tcriteria', Thrift.Type.STRUCT, 7); + this.tcriteria.write(output); + output.writeFieldEnd(); + } + if (this.tbinary !== null && this.tbinary !== undefined) { + output.writeFieldBegin('tbinary', Thrift.Type.STRING, 8); + output.writeBinary(this.tbinary); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; diff --git a/concourse-driver-node-js/src/thrift/concourse_types.js b/concourse-driver-node-js/src/thrift/concourse_types.js new file mode 100644 index 0000000000..34642b7451 --- /dev/null +++ b/concourse-driver-node-js/src/thrift/concourse_types.js @@ -0,0 +1,23 @@ +// +// Autogenerated by Thrift Compiler (0.12.0) +// +// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING +// +"use strict"; + +const thrift = require('thrift'); +const Thrift = thrift.Thrift; + +const data_ttypes = require('./data_types'); +const shared_ttypes = require('./shared_types'); +const exceptions_ttypes = require('./exceptions_types'); +const complex_ttypes = require('./complex_types'); + + +const ttypes = module.exports = {}; +ttypes.VERSION = '0.10.0'; +ttypes.NULL = new data_ttypes.TObject({ + 'data' : Buffer.alloc(0), + 'type' : 9 +}); +ttypes.JSON_RESERVED_IDENTIFIER_NAME = '$id$'; diff --git a/concourse-driver-node-js/src/thrift/data_types.js b/concourse-driver-node-js/src/thrift/data_types.js new file mode 100644 index 0000000000..b5d7c7848f --- /dev/null +++ b/concourse-driver-node-js/src/thrift/data_types.js @@ -0,0 +1,230 @@ +// +// Autogenerated by Thrift Compiler (0.12.0) +// +// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING +// +"use strict"; + +const thrift = require('thrift'); +const Thrift = thrift.Thrift; + +const shared_ttypes = require('./shared_types'); + + +const ttypes = module.exports = {}; +ttypes.TSymbolType = { + 'CONJUNCTION' : 1, + 'KEY' : 2, + 'VALUE' : 3, + 'PARENTHESIS' : 4, + 'OPERATOR' : 5, + 'TIMESTAMP' : 6 +}; +const TObject = module.exports.TObject = class { + constructor(args) { + this.data = null; + this.type = 7; + if (args) { + if (args.data !== undefined && args.data !== null) { + this.data = args.data; + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field data is unset!'); + } + if (args.type !== undefined && args.type !== null) { + this.type = args.type; + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field type is unset!'); + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.data = input.readBinary(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I32) { + this.type = input.readI32(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('TObject'); + if (this.data !== null && this.data !== undefined) { + output.writeFieldBegin('data', Thrift.Type.STRING, 1); + output.writeBinary(this.data); + output.writeFieldEnd(); + } + if (this.type !== null && this.type !== undefined) { + output.writeFieldBegin('type', Thrift.Type.I32, 2); + output.writeI32(this.type); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const TSymbol = module.exports.TSymbol = class { + constructor(args) { + this.type = null; + this.symbol = null; + if (args) { + if (args.type !== undefined && args.type !== null) { + this.type = args.type; + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field type is unset!'); + } + if (args.symbol !== undefined && args.symbol !== null) { + this.symbol = args.symbol; + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field symbol is unset!'); + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.I32) { + this.type = input.readI32(); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.STRING) { + this.symbol = input.readString(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('TSymbol'); + if (this.type !== null && this.type !== undefined) { + output.writeFieldBegin('type', Thrift.Type.I32, 1); + output.writeI32(this.type); + output.writeFieldEnd(); + } + if (this.symbol !== null && this.symbol !== undefined) { + output.writeFieldBegin('symbol', Thrift.Type.STRING, 2); + output.writeString(this.symbol); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const TCriteria = module.exports.TCriteria = class { + constructor(args) { + this.symbols = null; + if (args) { + if (args.symbols !== undefined && args.symbols !== null) { + this.symbols = Thrift.copyList(args.symbols, [ttypes.TSymbol]); + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field symbols is unset!'); + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.LIST) { + this.symbols = []; + const _rtmp31 = input.readListBegin(); + const _size0 = _rtmp31.size || 0; + for (let _i2 = 0; _i2 < _size0; ++_i2) { + let elem3 = null; + elem3 = new ttypes.TSymbol(); + elem3.read(input); + this.symbols.push(elem3); + } + input.readListEnd(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('TCriteria'); + if (this.symbols !== null && this.symbols !== undefined) { + output.writeFieldBegin('symbols', Thrift.Type.LIST, 1); + output.writeListBegin(Thrift.Type.STRUCT, this.symbols.length); + for (let iter4 in this.symbols) { + if (this.symbols.hasOwnProperty(iter4)) { + iter4 = this.symbols[iter4]; + iter4.write(output); + } + } + output.writeListEnd(); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; diff --git a/concourse-driver-node-js/src/thrift/exceptions_types.js b/concourse-driver-node-js/src/thrift/exceptions_types.js new file mode 100644 index 0000000000..71dbd32500 --- /dev/null +++ b/concourse-driver-node-js/src/thrift/exceptions_types.js @@ -0,0 +1,365 @@ +// +// Autogenerated by Thrift Compiler (0.12.0) +// +// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING +// +"use strict"; + +const thrift = require('thrift'); +const Thrift = thrift.Thrift; + + +const ttypes = module.exports = {}; +const DuplicateEntryException = module.exports.DuplicateEntryException = class extends Thrift.TException { + constructor(args) { + super(args); + this.name = "DuplicateEntryException"; + this.message = null; + if (args) { + if (args.message !== undefined && args.message !== null) { + this.message = args.message; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.message = input.readString(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('DuplicateEntryException'); + if (this.message !== null && this.message !== undefined) { + output.writeFieldBegin('message', Thrift.Type.STRING, 1); + output.writeString(this.message); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const InvalidArgumentException = module.exports.InvalidArgumentException = class extends Thrift.TException { + constructor(args) { + super(args); + this.name = "InvalidArgumentException"; + this.message = null; + if (args) { + if (args.message !== undefined && args.message !== null) { + this.message = args.message; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.message = input.readString(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('InvalidArgumentException'); + if (this.message !== null && this.message !== undefined) { + output.writeFieldBegin('message', Thrift.Type.STRING, 1); + output.writeString(this.message); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ParseException = module.exports.ParseException = class extends Thrift.TException { + constructor(args) { + super(args); + this.name = "ParseException"; + this.message = null; + if (args) { + if (args.message !== undefined && args.message !== null) { + this.message = args.message; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.message = input.readString(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ParseException'); + if (this.message !== null && this.message !== undefined) { + output.writeFieldBegin('message', Thrift.Type.STRING, 1); + output.writeString(this.message); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const SecurityException = module.exports.SecurityException = class extends Thrift.TException { + constructor(args) { + super(args); + this.name = "SecurityException"; + this.message = null; + if (args) { + if (args.message !== undefined && args.message !== null) { + this.message = args.message; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.message = input.readString(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('SecurityException'); + if (this.message !== null && this.message !== undefined) { + output.writeFieldBegin('message', Thrift.Type.STRING, 1); + output.writeString(this.message); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const TransactionException = module.exports.TransactionException = class extends Thrift.TException { + constructor(args) { + super(args); + this.name = "TransactionException"; + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + if (ftype == Thrift.Type.STOP) { + break; + } + input.skip(ftype); + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('TransactionException'); + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const ManagementException = module.exports.ManagementException = class extends Thrift.TException { + constructor(args) { + super(args); + this.name = "ManagementException"; + this.message = null; + if (args) { + if (args.message !== undefined && args.message !== null) { + this.message = args.message; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.message = input.readString(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('ManagementException'); + if (this.message !== null && this.message !== undefined) { + output.writeFieldBegin('message', Thrift.Type.STRING, 1); + output.writeString(this.message); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const PermissionException = module.exports.PermissionException = class extends Thrift.TException { + constructor(args) { + super(args); + this.name = "PermissionException"; + this.message = null; + if (args) { + if (args.message !== undefined && args.message !== null) { + this.message = args.message; + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.message = input.readString(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('PermissionException'); + if (this.message !== null && this.message !== undefined) { + output.writeFieldBegin('message', Thrift.Type.STRING, 1); + output.writeString(this.message); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; diff --git a/concourse-driver-node-js/src/thrift/shared_types.js b/concourse-driver-node-js/src/thrift/shared_types.js new file mode 100644 index 0000000000..c2054ddf8b --- /dev/null +++ b/concourse-driver-node-js/src/thrift/shared_types.js @@ -0,0 +1,166 @@ +// +// Autogenerated by Thrift Compiler (0.12.0) +// +// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING +// +"use strict"; + +const thrift = require('thrift'); +const Thrift = thrift.Thrift; + + +const ttypes = module.exports = {}; +ttypes.Operator = { + 'REGEX' : 1, + 'NOT_REGEX' : 2, + 'EQUALS' : 3, + 'NOT_EQUALS' : 4, + 'GREATER_THAN' : 5, + 'GREATER_THAN_OR_EQUALS' : 6, + 'LESS_THAN' : 7, + 'LESS_THAN_OR_EQUALS' : 8, + 'BETWEEN' : 9, + 'LINKS_TO' : 10, + 'LIKE' : 11, + 'NOT_LIKE' : 12 +}; +ttypes.Type = { + 'BOOLEAN' : 1, + 'DOUBLE' : 2, + 'FLOAT' : 3, + 'INTEGER' : 4, + 'LONG' : 5, + 'LINK' : 6, + 'STRING' : 7, + 'TAG' : 8, + 'NULL' : 9, + 'TIMESTAMP' : 10 +}; +ttypes.Diff = { + 'ADDED' : 1, + 'REMOVED' : 2 +}; +const AccessToken = module.exports.AccessToken = class { + constructor(args) { + this.data = null; + if (args) { + if (args.data !== undefined && args.data !== null) { + this.data = args.data; + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field data is unset!'); + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRING) { + this.data = input.readBinary(); + } else { + input.skip(ftype); + } + break; + case 0: + input.skip(ftype); + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('AccessToken'); + if (this.data !== null && this.data !== undefined) { + output.writeFieldBegin('data', Thrift.Type.STRING, 1); + output.writeBinary(this.data); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; +const TransactionToken = module.exports.TransactionToken = class { + constructor(args) { + this.accessToken = null; + this.timestamp = null; + if (args) { + if (args.accessToken !== undefined && args.accessToken !== null) { + this.accessToken = new ttypes.AccessToken(args.accessToken); + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field accessToken is unset!'); + } + if (args.timestamp !== undefined && args.timestamp !== null) { + this.timestamp = args.timestamp; + } else { + throw new Thrift.TProtocolException(Thrift.TProtocolExceptionType.UNKNOWN, 'Required field timestamp is unset!'); + } + } + } + + read (input) { + input.readStructBegin(); + while (true) { + const ret = input.readFieldBegin(); + const ftype = ret.ftype; + const fid = ret.fid; + if (ftype == Thrift.Type.STOP) { + break; + } + switch (fid) { + case 1: + if (ftype == Thrift.Type.STRUCT) { + this.accessToken = new ttypes.AccessToken(); + this.accessToken.read(input); + } else { + input.skip(ftype); + } + break; + case 2: + if (ftype == Thrift.Type.I64) { + this.timestamp = input.readI64(); + } else { + input.skip(ftype); + } + break; + default: + input.skip(ftype); + } + input.readFieldEnd(); + } + input.readStructEnd(); + return; + } + + write (output) { + output.writeStructBegin('TransactionToken'); + if (this.accessToken !== null && this.accessToken !== undefined) { + output.writeFieldBegin('accessToken', Thrift.Type.STRUCT, 1); + this.accessToken.write(output); + output.writeFieldEnd(); + } + if (this.timestamp !== null && this.timestamp !== undefined) { + output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); + output.writeI64(this.timestamp); + output.writeFieldEnd(); + } + output.writeFieldStop(); + output.writeStructEnd(); + return; + } + +}; diff --git a/concourse-driver-node-js/src/utilities/convert.js b/concourse-driver-node-js/src/utilities/convert.js new file mode 100644 index 0000000000..0f1ee16e32 --- /dev/null +++ b/concourse-driver-node-js/src/utilities/convert.js @@ -0,0 +1,20 @@ +'use strict' + +const _$isMap = require('lodash/isMap') +// const _$isPlainObject = require('lodash/isPlainObject') +// const _$mapValues = require('lodash/mapValues') +// const _$toPairs = require('lodash/toPairs') +// const concourseThriftDataTypes = require('../thrift/data_types') + +class Convert { + static javascriptify(thriftData) { + if (_$isMap(thriftData)) { + // const result = new Map() + // // + // // + // return result + } + } +} + +exports = module.exports = Convert diff --git a/concourse-driver-node-js/src/utilities/index.js b/concourse-driver-node-js/src/utilities/index.js new file mode 100644 index 0000000000..9103f460c9 --- /dev/null +++ b/concourse-driver-node-js/src/utilities/index.js @@ -0,0 +1,5 @@ +'use strict' + +const Convert = require('./convert') + +exports = module.exports = { Convert } diff --git a/concourse-driver-node-js/tools/thrift-transformers/remove-server-code.js b/concourse-driver-node-js/tools/thrift-transformers/remove-server-code.js new file mode 100755 index 0000000000..a82df83c6f --- /dev/null +++ b/concourse-driver-node-js/tools/thrift-transformers/remove-server-code.js @@ -0,0 +1,98 @@ +#!/usr/bin/env node + +'use strict' + +const _$endsWith = require('lodash/endsWith') +const _$startsWith = require('lodash/startsWith') +const astTypes = require('ast-types') +const fs = require('fs') +const path = require('path') +const recast = require('recast') +const yargs = require('yargs') + +const processFile = (javascriptFilePath, javascriptSource) => { + const javascriptSourceAst = recast.parse(javascriptSource) + const javascriptSourceAstNodePath = new astTypes.NodePath(javascriptSourceAst.program) + javascriptSourceAstNodePath + .get('body') + .each((path) => { + if (astTypes.namedTypes.VariableDeclaration.check(path.node)) { + path + .get('declarations') + .each((path) => { + if (! astTypes.namedTypes.VariableDeclarator.check(path.node)) { + return + } + const pathIdPath = path.get('id') + if (! astTypes.namedTypes.Identifier.check(pathIdPath.node)) { + return + } + if (pathIdPath.node.name === 'ConcourseServiceProcessor') { + path.prune() + } else if (_$startsWith(pathIdPath.node.name, 'ConcourseService_') && + _$endsWith(pathIdPath.node.name, '_args')) { + path + .get('init', 'body', 'body') + .each((path) => { + if (! astTypes.namedTypes.MethodDefinition.check(path.node)) { + return + } + const pathKeyPath = path.get('key') + if (! astTypes.namedTypes.Identifier.check(pathKeyPath.node)) { + return + } + if (pathKeyPath.node.name === 'read') { + path.prune() + } + }) + } else if (_$startsWith(pathIdPath.node.name, 'ConcourseService_') && + _$endsWith(pathIdPath.node.name, '_result')) { + path + .get('init', 'body', 'body') + .each((path) => { + if (! astTypes.namedTypes.MethodDefinition.check(path.node)) { + return + } + const pathKeyPath = path.get('key') + if (! astTypes.namedTypes.Identifier.check(pathKeyPath.node)) { + return + } + if (pathKeyPath.node.name === 'write') { + path.prune() + } + }) + } + }) + } + }) + const updatedJavascriptSource = recast + .print(javascriptSourceAst) + .code + fs.writeFileSync(javascriptFilePath, updatedJavascriptSource, 'utf8') +} + +const main = (argv) => { + yargs + .command({ + builder: (yargs) => { + yargs + .positional('javascript-file', { + coerce: (filePath) => { + return path.resolve(filePath) + } + }) + .version(false) + }, + command: '$0 ', + desc: 'Parses JavaScript code generated by Thrift and removes server code', + handler: (argv) => { + const { javascriptFile: javascriptFilePath } = argv + const javascriptSource = fs.readFileSync(javascriptFilePath, 'utf8') + processFile(javascriptFilePath, javascriptSource) + } + }) + .parse(argv) +} + +const argv = process.argv.slice(2) +main(argv) diff --git a/concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js b/concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js new file mode 100755 index 0000000000..41df01949a --- /dev/null +++ b/concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js @@ -0,0 +1,197 @@ +#!/usr/bin/env node + +'use strict' + +const _$filter = require('lodash/filter') +const _$find = require('lodash/find') +const _$isEmpty = require('lodash/isEmpty') +const _$isUndefined = require('lodash/isUndefined') +const _$map = require('lodash/map') +const astTypes = require('ast-types') +const fs = require('fs') +const path = require('path') +const recast = require('recast') +const thriftParser = require('@creditkarma/thrift-parser') +const yargs = require('yargs') + +const _thriftReturnTypeHasThriftMap = (typeAst) => { + if (typeAst.type === 'MapType') { return true } + if (! _$isUndefined(typeAst.valueType)) { + return _thriftReturnTypeHasThriftMap(typeAst.valueType) + } + if (! _$isUndefined(typeAst.keyType)) { + return _thriftReturnTypeHasThriftMap(typeAst.keyType) + } + return false +} + +const processFile = (thriftFilePath, javascriptFilePath, thriftSource, javascriptSource) => { + const thriftSourceAst = thriftParser.parse(thriftSource) + const thriftConcourseServiceDefinitionAst = _$find(thriftSourceAst.body, { + name: { value: 'ConcourseService' }, + type: 'ServiceDefinition' + }) + const { functions: thriftConcourseServiceMethodsAst } = thriftConcourseServiceDefinitionAst + let methodsWithMapsInReturnValueAst = _$filter(thriftConcourseServiceMethodsAst, (methodAst) => {// + return _thriftReturnTypeHasThriftMap(methodAst.returnType) + }) + const methodsWithMapsInReturnValue = _$map(methodsWithMapsInReturnValueAst, (methodAst) => methodAst.name.value) + let methodResultClassesToCheck = _$map(methodsWithMapsInReturnValue, (methodName) => `ConcourseService_${methodName}_result`) + methodResultClassesToCheck = new Set(methodResultClassesToCheck) + const javascriptSourceAst = recast.parse(javascriptSource) + const javascriptSourceAstNodePath = new astTypes.NodePath(javascriptSourceAst.program) + javascriptSourceAstNodePath + .get('body') + .each((path) => { + if (astTypes.namedTypes.VariableDeclaration.check(path.node)) { + path + .get('declarations') + .each((path) => { + if (! astTypes.namedTypes.VariableDeclarator.check(path.node)) { + return + } + const pathIdPath = path.get('id') + if (! astTypes.namedTypes.Identifier.check(pathIdPath.node)) { + return + } + if (methodResultClassesToCheck.has(pathIdPath.node.name)) { + console.log(`In method result class "${pathIdPath.node.name}"`) + path + .get('init', 'body', 'body') + .each((path) => { + if (! astTypes.namedTypes.MethodDefinition.check(path.node)) { + return + } + const pathKeyPath = path.get('key') + if (! astTypes.namedTypes.Identifier.check(pathKeyPath.node)) { + return + } + if (pathKeyPath.node.name === 'read') { + console.log(` > In method "read" of method result class "${pathIdPath.node.name}"`) + const emptyObjectAssignmentsFound = {} + const mapVariableNames = new Set() + const readMethodBlockPath = path.get('value', 'body', 'body') + astTypes.visit(readMethodBlockPath.node, { + visitAssignmentExpression(path) { + try { + if (path.node.operator !== '=') { + this.abort() + } + const pathRightPath = path.get('right') + if ((! astTypes.namedTypes.ObjectExpression.check(pathRightPath.node)) || + (! _$isEmpty(pathRightPath.node.properties))) { + this.abort() + } + emptyObjectAssignmentsFound[path.node.loc.start.line] = path + } catch (error) { + if (error instanceof this.AbortRequest) { + return false + } else { + throw error + } + } + this.traverse(path) + } + }) + astTypes.visit(readMethodBlockPath.node, { + visitCallExpression(path) { + try { + const pathCalleePath = path.get('callee') + if (! astTypes.namedTypes.MemberExpression.check(pathCalleePath.node)) { + this.abort() + } + const { code: parsedPathCallee } = recast.print(pathCalleePath.node) + if (parsedPathCallee !== 'input.readMapBegin') { + this.abort() + } + const emptyObjectAssignmentPath = emptyObjectAssignmentsFound[pathCalleePath.node.loc.start.line - 1] + if (_$isUndefined(emptyObjectAssignmentPath)) { + this.abort() + } + const emptyObjectAssignmentPathLeftPath = emptyObjectAssignmentPath.get('left') + const { code: emptyObjectAssignmentVariableName } = recast.print(emptyObjectAssignmentPathLeftPath.node) + mapVariableNames.add(emptyObjectAssignmentVariableName) + const emptyObjectAssignmentPathRightPath = emptyObjectAssignmentPath.get('right') + emptyObjectAssignmentPathRightPath.replace( + astTypes.builders.newExpression( + astTypes.builders.identifier('Map'), + [])) + } catch (error) { + if (error instanceof this.AbortRequest) { + return false + } else { + throw error + } + } + this.traverse(path) + } + }) + astTypes.visit(readMethodBlockPath.node, { + visitMemberExpression(path) { + try { + debugger + // const { code: memberExpressionValue } = recast.print(path.node) + const pathObjectPath = path.get('object') + const { code: memberExpressionValue } = recast.print(pathObjectPath.node) + // if () { + // this.abort() + // } + console.log(`memberExpressionValue === ${memberExpressionValue}`) + } catch (error) { + if (error instanceof this.AbortRequest) { + return false + } else { + throw error + } + } + this.traverse(path) + } + }) + // + } + }) + console.log('\n') + } + }) + } + }) + const updatedJavascriptSource = recast + .print(javascriptSourceAst) + .code + fs.writeFileSync(javascriptFilePath, updatedJavascriptSource, 'utf8') +} + +const main = (argv) => { + yargs + .command({ + builder: (yargs) => { + yargs + .positional('javascript-file', { + coerce: (filePath) => { + return path.resolve(filePath) + } + }) + .positional('thrift-file', { + coerce: (filePath) => { + return path.resolve(filePath) + } + }) + .version(false) + }, + command: '$0 ', + desc: 'Parses JavaScript code generated by Thrift and patches all types that were Thrift maps to actual JavaScript maps', + handler: (argv) => { + const { + javascriptFile: javascriptFilePath, + thriftFile: thriftFilePath + } = argv + const javascriptSource = fs.readFileSync(javascriptFilePath, 'utf8') + const thriftSource = fs.readFileSync(thriftFilePath, 'utf8') + processFile(thriftFilePath, javascriptFilePath, thriftSource, javascriptSource) + } + }) + .parse(argv) +} + +const argv = process.argv.slice(2) +main(argv) diff --git a/interface/complex.thrift b/interface/complex.thrift index 41551a7a25..579aa96305 100644 --- a/interface/complex.thrift +++ b/interface/complex.thrift @@ -23,6 +23,10 @@ include "data.thrift" # thrift -out concourse-driver-java/src/main/java -gen java interface/complex.thrift namespace java com.cinchapi.concourse.thrift +# To generate Node.js source code run: +# thrift --gen js:es6,node -out concourse-driver-node-js/src -recurse interface/complex.thrift +namespace js concourse.thrift.complex + # To generate python source code run: # thrift -out concourse-driver-python -gen py interface/complex.thrift namespace py concourse.thriftapi.complex diff --git a/interface/concourse.thrift b/interface/concourse.thrift index 9cb355f4b7..f19e5af692 100644 --- a/interface/concourse.thrift +++ b/interface/concourse.thrift @@ -25,6 +25,10 @@ include "complex.thrift" # utils/compile-thrift-java.sh namespace java com.cinchapi.concourse.thrift +# To generate Node.js source code run: +# utils/compile—thrift-node-js.sh +namespace js concourse.thrift + # To generate python source code run: # utils/compile—thrift-python.sh namespace py concourse.thriftapi diff --git a/interface/data.thrift b/interface/data.thrift index 3ff7269035..7b91fc8c2c 100644 --- a/interface/data.thrift +++ b/interface/data.thrift @@ -25,6 +25,10 @@ include "shared.thrift" # thrift -out concourse-driver-java/src/main/java -gen java interface/data.thrift namespace java com.cinchapi.concourse.thrift +# To generate Node.js source code run: +# thrift --gen js:es6,node -out concourse-driver-node-js/src -recurse interface/data.thrift +namespace js concourse.thrift.data + # To generate python source code run: # thrift -out concourse-driver-python -gen py interface/data.thrift namespace py concourse.thriftapi.data diff --git a/interface/exceptions.thrift b/interface/exceptions.thrift index 9707a95bc0..9c26208bd0 100644 --- a/interface/exceptions.thrift +++ b/interface/exceptions.thrift @@ -23,6 +23,10 @@ # thrift -out concourse-driver-java/src/main/java -gen java interface/exceptions.thrift namespace java com.cinchapi.concourse.thrift +# To generate Node.js source code run: +# thrift --gen js:es6,node -out concourse-driver-node-js/src -recurse interface/exceptions.thrift +namespace js concourse.thrift.exceptions + # To generate python source code run: # thrift -out concourse-driver-python -gen py interface/exceptions.thrift namespace py concourse.thriftapi.exceptions @@ -103,7 +107,7 @@ exception ManagementException { } /** - * Thrown when a user attempts an operation for which she has insufficient + * Thrown when a user attempts an operation for which she has insufficient * permission. */ exception PermissionException { diff --git a/interface/shared.thrift b/interface/shared.thrift index 4eda83931f..5e98768cd5 100644 --- a/interface/shared.thrift +++ b/interface/shared.thrift @@ -21,6 +21,10 @@ # thrift -out concourse-driver-java/src/main/java -gen java interface/shared.thrift namespace java com.cinchapi.concourse.thrift +# To generate Node.js source code run: +# thrift --gen js:es6,node -out concourse-driver-node-js/src -recurse interface/shared.thrift +namespace js concourse.thrift.shared + # To generate python source code run: # thrift -out concourse-driver-python -gen py interface/shared.thrift namespace py concourse.thriftapi.shared diff --git a/utils/compile-thrift-node-js.sh b/utils/compile-thrift-node-js.sh new file mode 100755 index 0000000000..f5b0843fa0 --- /dev/null +++ b/utils/compile-thrift-node-js.sh @@ -0,0 +1,41 @@ +#!/usr/bin/env bash + +# Copyright (c) 2015 Cinchapi Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Compile the thrift API for the Node.js service + +. "`dirname "$0"`/.compile-thrift-include" + +TARGET="../concourse-driver-node-js" +PACKAGE=$TARGET"/src/thrift" + +cd $THRIFT_DIR + +# Run the thrift compile +thrift --gen js:es6,node -out $PACKAGE -recurse concourse.thrift + +if [ $? -ne 0 ]; then + exit 1 +fi + +# Patch the `NULL` type in the "concourse_types.js" file with a `data` property so that it validates properly. +perl -e 's#^(var\sthrift\s=\srequire\('"'"'thrift'"'"'\);)$#var buffer = require('"'"'buffer'"'"');\nvar Buffer = buffer.Buffer;\n$1#m' -i -p $PACKAGE"/concourse_types.js" +perl -e 's#^(\s{2}'"'"'type'"'"'\s:\s9)$# '"'"'data'"'"' : Buffer.alloc(0),\n$1#m' -i -p $PACKAGE"/concourse_types.js" +$TARGET"/tools/thrift-transformers/remove-server-code.js" $PACKAGE"/ConcourseService.js" +# $TARGET"/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js" $TARGET"/../interface/concourse.thrift" $PACKAGE"/ConcourseService.js" + +echo "Finished compiling the Thrift API for Node.js to "$(cd $PACKAGE && pwd) + +exit 0 From 78ace6fd06106da9036bbddbe532f8bd5ec57251 Mon Sep 17 00:00:00 2001 From: Jonathan Barronville Date: Fri, 21 Jun 2019 22:47:37 -0400 Subject: [PATCH 10/10] Made some significant updates to the Node.js driver for Concourse. --- concourse-driver-node-js/package-lock.json | 10 + concourse-driver-node-js/package.json | 3 + concourse-driver-node-js/src/client/errors.js | 150 +- concourse-driver-node-js/src/client/index.js | 290 +- concourse-driver-node-js/src/index.js | 12 +- concourse-driver-node-js/src/link.js | 39 + concourse-driver-node-js/src/long.js | 33 + concourse-driver-node-js/src/tag.js | 36 + .../src/thrift/ConcourseService.js | 720 +- .../src/thrift/ConcourseService.js.bak | 101112 --------------- .../src/thrift/concourse_types.js | 2 + .../src/utilities/convert.js | 188 +- ...ift-map-return-types-to-javascript-maps.js | 30 +- utils/compile-thrift-node-js.sh | 14 +- 14 files changed, 920 insertions(+), 101719 deletions(-) create mode 100644 concourse-driver-node-js/src/link.js create mode 100644 concourse-driver-node-js/src/long.js create mode 100644 concourse-driver-node-js/src/tag.js delete mode 100644 concourse-driver-node-js/src/thrift/ConcourseService.js.bak diff --git a/concourse-driver-node-js/package-lock.json b/concourse-driver-node-js/package-lock.json index 32b31813e0..879aefba5a 100644 --- a/concourse-driver-node-js/package-lock.json +++ b/concourse-driver-node-js/package-lock.json @@ -41,6 +41,11 @@ "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.5.5.tgz", "integrity": "sha512-5am6HnnfN+urzt4yfg7IgTbotDjIT/u8AJpEt0sIU9FtXfVeezXAPKswrG+xKUCOYAINpSdgZVDU6QFh+cuH3w==" }, + "bn.js": { + "version": "4.11.8", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.11.8.tgz", + "integrity": "sha512-ItfYfPLkWHUjckQCk8xC+LwxgK8NYcXywGigJgSwOP8Y2iyWT4f2vsZnoOXTTbo+o5yXmIUJ4gn5538SO5S3gA==" + }, "camelcase": { "version": "5.3.1", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", @@ -205,6 +210,11 @@ "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==" }, + "luxon": { + "version": "1.16.0", + "resolved": "https://registry.npmjs.org/luxon/-/luxon-1.16.0.tgz", + "integrity": "sha512-qaqB+JwpGwtl7UbIXng3A/l4W/ySBr8drQvwtMLZBMiLD2V+0fEnPWMrs+UjnIy9PsktazQaKvwDUCLzoWz0Hw==" + }, "map-age-cleaner": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", diff --git a/concourse-driver-node-js/package.json b/concourse-driver-node-js/package.json index f1d5b0b604..81126d8f53 100644 --- a/concourse-driver-node-js/package.json +++ b/concourse-driver-node-js/package.json @@ -3,8 +3,11 @@ "bugs": "https://github.com/cinchapi/concourse/issues", "dependencies": { "bluebird": "^3.5.5", + "bn.js": "^4.11.8", "java-properties": "^1.0.1", "lodash": "^4.17.11", + "luxon": "^1.16.0", + "node-int64": "^0.4.0", "thrift": "^0.12.0" }, "description": "The Node.js driver for the Concourse database system.", diff --git a/concourse-driver-node-js/src/client/errors.js b/concourse-driver-node-js/src/client/errors.js index 0c063b4356..da3e09167c 100644 --- a/concourse-driver-node-js/src/client/errors.js +++ b/concourse-driver-node-js/src/client/errors.js @@ -4,88 +4,90 @@ const _$assign = require('lodash/assign') const _$isFunction = require('lodash/isFunction') const _$pick = require('lodash/pick') -class ConnectionError extends Error { - constructor(options) { - options = _$assign({}, { - host: null, - originalError: null, - port: null - }, options) - options = _$pick(options, [ - 'host', - 'originalError', - 'port' - ]) - const message = `There was error connecting to the Concourse Server at ${options.host}:${options.port}` - Error.call(this, message) - Object.defineProperties(this, { - extra: { - enumerable: true, - value: _$assign({}, options) - }, - message: { - enumerable: true, - value: message - }, - name: { - enumerable: true, - value: `Client.${this.constructor.name}` - } - }) - Object.freeze(this.extra) - if (_$isFunction(Error.captureStackTrace)) { - Error.captureStackTrace(this, this.constructor) - } else { - const { stack } = new Error(message) - Object.defineProperty(this, 'stack', { - enumerable: true, - value: stack - }) +const ConnectionError = function ConnectionError(options) { + options = _$assign({}, { + host: null, + originalError: null, + port: null + }, options) + options = _$pick(options, [ + 'host', + 'originalError', + 'port' + ]) + const message = `There was error connecting to the Concourse Server at ${options.host}:${options.port}` + Error.call(this, message) + Object.defineProperties(this, { + extra: { + enumerable: true, + value: _$assign({}, options) + }, + message: { + enumerable: true, + value: message + }, + name: { + enumerable: true, + value: `Client.${this.constructor.name}` } + }) + Object.freeze(this.extra) + if (_$isFunction(Error.captureStackTrace)) { + Error.captureStackTrace(this, this.constructor) + } else { + const { stack } = new Error(message) + Object.defineProperty(this, 'stack', { + enumerable: true, + value: stack + }) } } -class ThriftClientMethodError extends Error { - constructor(options) { - options = _$assign({}, { - arguments: null, - error: null, - method: null - }, options) - options = _$pick(options, [ - 'arguments', - 'error', - 'method' - ]) - const message = `There was error calling the method \`${options.method}\` on the Thrift client` - Error.call(this, message) - Object.defineProperties(this, { - extra: { - enumerable: true, - value: _$assign({}, options) - }, - message: { - enumerable: true, - value: message - }, - name: { - enumerable: true, - value: `Client.${this.constructor.name}` - } - }) - Object.freeze(this.extra) - if (_$isFunction(Error.captureStackTrace)) { - Error.captureStackTrace(this, this.constructor) - } else { - const { stack } = new Error(message) - Object.defineProperty(this, 'stack', { - enumerable: true, - value: stack - }) +ConnectionError.prototype = Object.create(Error.prototype) +ConnectionError.prototype.constructor = ConnectionError + +const ThriftClientMethodError = function ThriftClientMethodError(options) { + options = _$assign({}, { + arguments: null, + error: null, + method: null + }, options) + options = _$pick(options, [ + 'arguments', + 'error', + 'method' + ]) + const message = `There was error calling the method \`${options.method}\` on the Thrift client` + Error.call(this, message) + Object.defineProperties(this, { + extra: { + enumerable: true, + value: _$assign({}, options) + }, + message: { + enumerable: true, + value: message + }, + name: { + enumerable: true, + value: `Client.${this.constructor.name}` } + }) + Object.freeze(this.extra) + if (_$isFunction(Error.captureStackTrace)) { + Error.captureStackTrace(this, this.constructor) + } else { + const { stack } = new Error(message) + Object.defineProperty(this, 'stack', { + enumerable: true, + value: stack + }) } } +ThriftClientMethodError.prototype = Object.create(Error.prototype) +ThriftClientMethodError.prototype.constructor = ThriftClientMethodError + exports = module.exports = { ConnectionError, ThriftClientMethodError diff --git a/concourse-driver-node-js/src/client/index.js b/concourse-driver-node-js/src/client/index.js index 348832c1e4..f53485b096 100644 --- a/concourse-driver-node-js/src/client/index.js +++ b/concourse-driver-node-js/src/client/index.js @@ -15,167 +15,167 @@ const Promise = require('bluebird') const thrift = require('thrift') const utilities = require('../utilities') -class Client { - constructor(options) { - return (async (options) => { - options = _$assign({}, options) - const defaultOptions = { - environment: '', - host: 'localhost', - password: 'admin', - port: 1717, - username: 'admin' +const Client = function Client(options) { + return (async (options) => { + options = _$assign({}, options) + const defaultOptions = { + environment: '', + host: 'localhost', + password: 'admin', + port: 1717, + username: 'admin' + } + if (_$isString(options.prefs)) { + options.prefs = path.resolve(options.prefs) + const preferencesFileProperties = javaProperties.of(options.prefs) + delete options.prefs + const preferencesFileOptions = { + environment: preferencesFileProperties.get('environment'), + host: preferencesFileProperties.get('host'), + password: preferencesFileProperties.get('password'), + port: preferencesFileProperties.getInt('port'), + username: preferencesFileProperties.get('username') } - if (_$isString(options.prefs)) { - options.prefs = path.resolve(options.prefs) - const preferencesFileProperties = javaProperties.of(options.prefs) - delete options.prefs - const preferencesFileOptions = { - environment: preferencesFileProperties.get('environment'), - host: preferencesFileProperties.get('host'), - password: preferencesFileProperties.get('password'), - port: preferencesFileProperties.getInt('port'), - username: preferencesFileProperties.get('username') + _$forEach(defaultOptions, (defaultOptionValue, optionKey) => { + if (_$isUndefined(options[optionKey])) { + options[optionKey] = (! _$isUndefined(preferencesFileOptions[optionKey])) ? preferencesFileOptions[optionKey] : defaultOptionValue } - _$forEach(defaultOptions, (defaultOptionValue, optionKey) => { - if (_$isUndefined(options[optionKey])) { - options[optionKey] = (! _$isUndefined(preferencesFileOptions[optionKey])) ? preferencesFileOptions[optionKey] : defaultOptionValue - } - }) - } else { - _$forEach(defaultOptions, (defaultOptionValue, optionKey) => { - options[optionKey] = (! _$isUndefined(options[optionKey])) ? options[optionKey] : defaultOptionValue - }) - } - options = _$pick(options, [ - 'environment', - 'host', - 'password', - 'port', - 'username' - ]) - _$forEach(options, (optionValue, optionKey) => { - Object.defineProperty(this, optionKey, { value: optionValue }) - }) - await this.connect() - Object.defineProperty(this, 'credentials', { - value: await this.authenticate() }) - Object.defineProperty(this, 'transaction', { - value: null, - writable: true - }) - return this - })(options) - } - - async _callThriftClientMethod(name, arguments_, reject) { - try { - return await this.client[name](...arguments_) - } catch (error) { - error = new Client.ThriftClientMethodError({ - arguments: arguments_, - error, - method: name + } else { + _$forEach(defaultOptions, (defaultOptionValue, optionKey) => { + options[optionKey] = (! _$isUndefined(options[optionKey])) ? options[optionKey] : defaultOptionValue }) - reject(error) } - } + options = _$pick(options, [ + 'environment', + 'host', + 'password', + 'port', + 'username' + ]) + _$forEach(options, (optionValue, optionKey) => { + Object.defineProperty(this, optionKey, { value: optionValue }) + }) + await this.connect() + Object.defineProperty(this, 'credentials', { + value: await this.authenticate() + }) + Object.defineProperty(this, 'transaction', { + value: null, + writable: true + }) + return this + })(options) +} - async authenticate() { - return new Promise(async (resolve, reject) => { - const credentials = await this._callThriftClientMethod('login', [ - this.username, - this.password, - this.environment - ], reject) - if (_$isUndefined(credentials)) { - return - } - resolve(credentials) +Client.connect = (...args) => { + return new Client(...args) +} + +Client.prototype._callThriftClientMethod = async function _callThriftClientMethod(name, arguments_, reject) { + try { + return await this.client[name](...arguments_) + } catch (error) { + error = new Client.ThriftClientMethodError({ + arguments: arguments_, + error, + method: name }) + reject(error) } +} - async connect() { - return new Promise((resolve, reject) => { - Object.defineProperty(this, 'connection', { - value: thrift.createConnection(this.host, this.port, { - protocol: thrift.TBinaryProtocol, - transport: thrift.TBufferedTransport - }) - }) - this.connection.on('error', (error) => { - error = new Client.ConnectionError({ - host: this.host, - originalError: error, - port: this.port - }) - reject(error) - }) - Object.defineProperty(this, 'client', { - value: thrift.createClient(ConcourseThriftService.Client, this.connection) +Client.prototype.authenticate = async function authenticate() { + return new Promise(async (resolve, reject) => { + const credentials = await this._callThriftClientMethod('login', [ + this.username, + this.password, + this.environment + ], reject) + if (_$isUndefined(credentials)) { + return + } + resolve(credentials) + }) +} + +Client.prototype.connect = async function connect() { + return new Promise((resolve, reject) => { + Object.defineProperty(this, 'connection', { + value: thrift.createConnection(this.host, this.port, { + protocol: thrift.TBinaryProtocol, + transport: thrift.TBufferedTransport }) - this.connection.on('connect', () => { - resolve() + }) + this.connection.on('error', (error) => { + error = new Client.ConnectionError({ + host: this.host, + originalError: error, + port: this.port }) + reject(error) }) - } - - select(options) { - return new Promise(async (resolve, reject) => { - options = _$assign({}, options) - let { criteria } = options - const keys = (! _$isUndefined(options.keys)) ? options.keys : options.key - let records = (! _$isUndefined(options.records)) ? options.records : options.record - const { timestamp } = options - let data - if (_$isArray(records) && - _$isUndefined(keys) && - _$isUndefined(timestamp)) { - data = await this._callThriftClientMethod('selectRecords', [ - records, - this.credentials, - this.transaction, - this.environment - ], reject) - if (_$isUndefined(data)) { return } - } else if (_$isArray(records) && - _$isNumber(timestamp) && - _$isUndefined(keys)) { - data = await this._callThriftClientMethod('selectRecordsTime', [ - records, - timestamp, - this.credentials, - this.transaction, - this.environment - ], reject) - if (_$isUndefined(data)) { return } - } else if (_$isArray(records) && - _$isString(timestamp) && - _$isUndefined(keys)) { - data = await this._callThriftClientMethod('selectRecordsTimestr', [ - records, - timestamp, - this.credentials, - this.transaction, - this.environment - ], reject) - if (_$isUndefined(data)) { return } - }// else if () { - // - //} - data = utilities.Convert.javascriptify(data) - resolve(data) + Object.defineProperty(this, 'client', { + value: thrift.createClient(ConcourseThriftService.Client, this.connection) }) - } + this.connection.on('connect', () => { + resolve() + }) + }) +} - toString() { - return `Connected to ${this.host}:${this.port} as ${this.username}` - } +Client.prototype.select = async function select(options) { + return new Promise(async (resolve, reject) => { + options = _$assign({}, options) + let { criteria } = options + const keys = (! _$isUndefined(options.keys)) ? options.keys : options.key + let records = (! _$isUndefined(options.records)) ? options.records : options.record + const { timestamp } = options + let data + if (_$isArray(records) && + _$isUndefined(keys) && + _$isUndefined(timestamp)) { + data = await this._callThriftClientMethod('selectRecords', [ + records, + this.credentials, + this.transaction, + this.environment + ], reject) + if (_$isUndefined(data)) { return } + } else if (_$isArray(records) && + _$isNumber(timestamp) && + _$isUndefined(keys)) { + data = await this._callThriftClientMethod('selectRecordsTime', [ + records, + timestamp, + this.credentials, + this.transaction, + this.environment + ], reject) + if (_$isUndefined(data)) { return } + } else if (_$isArray(records) && + _$isString(timestamp) && + _$isUndefined(keys)) { + data = await this._callThriftClientMethod('selectRecordsTimestr', [ + records, + timestamp, + this.credentials, + this.transaction, + this.environment + ], reject) + if (_$isUndefined(data)) { return } + }// else if () { + // + //} + data = utilities.Convert.javascriptify(data) + resolve(data) + }) } -_$assign(Client, errors) +Client.prototype.toString = function toString() { + return `Connected to ${this.host}:${this.port} as ${this.username}` +} -Client.connect = (...args) => new Client(...args) +_$assign(Client, errors) exports = module.exports = Client diff --git a/concourse-driver-node-js/src/index.js b/concourse-driver-node-js/src/index.js index 6ecd8f0340..9ca28bea26 100644 --- a/concourse-driver-node-js/src/index.js +++ b/concourse-driver-node-js/src/index.js @@ -1,7 +1,15 @@ 'use strict' const Client = require('./client') +const Link = require('./link') +const Long = require('./long') +const Tag = require('./tag') -const ConcourseDriver = { Client } +const Concourse = { + Client, + Link, + Long, + Tag +} -exports = module.exports = ConcourseDriver +exports = module.exports = Concourse diff --git a/concourse-driver-node-js/src/link.js b/concourse-driver-node-js/src/link.js new file mode 100644 index 0000000000..cfb5dd5be9 --- /dev/null +++ b/concourse-driver-node-js/src/link.js @@ -0,0 +1,39 @@ +'use strict' + +const _$isBuffer = require('lodash/isBuffer') +const _$isObject = require('lodash/isObject') +const Long = require('./long') + +const Link = function Link(record) { + if (_$isObject(record) && + _$isBuffer(record.buffer)) { + record = record.buffer + } + Long.call(this, record) +} + +Link.prototype = Object.create(Long.prototype) +Link.prototype.constructor = Link + +Link.prototype[Symbol.toPrimitive] = function (hint) { + return this.valueOf() +} + +Link.isLink = function isLink(value) { + return value instanceof Link +} + +Link.to = function to(...args) { + return new Link(...args) +} + +Link.toWhere = function toWhere(ccl) { + return `@${ccl}@` +} + +Link.prototype.toString = function toString() { + const value = Long.prototype.toString.call(this) + return `@${value}` +} + +exports = module.exports = Link diff --git a/concourse-driver-node-js/src/long.js b/concourse-driver-node-js/src/long.js new file mode 100644 index 0000000000..581f2ef459 --- /dev/null +++ b/concourse-driver-node-js/src/long.js @@ -0,0 +1,33 @@ +'use strict' + +const Int64 = require('node-int64') +const Int64Util = require('thrift/lib/nodejs/lib/thrift/int64_util') + +const Long = function Long(...args) { + if (! Long.isLong(this)) { + return new Long(...args) + } + Int64.call(this, ...args) +} + +Long.prototype = Object.create(Int64.prototype) +Long.prototype.constructor = Long + +Long.fromNumberString = function fromNumberString(string) { + const long = Int64Util.fromDecimalString(string) + return Long(long.buffer) +} + +Long.isLong = function isLong(value) { + return value instanceof Long +} + +Long.toNumberString = function toNumberString(long) { + return Int64Util.toDecimalString(long) +} + +// Long.prototype.toJSON = function toJSON() { +// return Long.toNumberString(this) +// } + +exports = module.exports = Long diff --git a/concourse-driver-node-js/src/tag.js b/concourse-driver-node-js/src/tag.js new file mode 100644 index 0000000000..bfd6fcd10d --- /dev/null +++ b/concourse-driver-node-js/src/tag.js @@ -0,0 +1,36 @@ +'use strict' + +const Tag = function Tag(value) { + String.call(this, value) + Object.defineProperty(this, 'value', { value }) + Object.defineProperty(this, 'length', { + get() { + return this.value.length + } + }) +} + +Tag.prototype = Object.create(String.prototype) +Tag.prototype.constructor = Tag + +Tag.prototype[Symbol.toPrimitive] = function (hint) { + return this.valueOf() +} + +Tag.create = function create(...args) { + return new Tag(...args) +} + +Tag.isTag = function isTag(value) { + return value instanceof Tag +} + +Tag.prototype.toString = function toString() { + return this.value +} + +Tag.prototype.valueOf = function valueOf() { + return this.value +} + +exports = module.exports = Tag diff --git a/concourse-driver-node-js/src/thrift/ConcourseService.js b/concourse-driver-node-js/src/thrift/ConcourseService.js index 4ef9a18e0c..d23955dbb6 100644 --- a/concourse-driver-node-js/src/thrift/ConcourseService.js +++ b/concourse-driver-node-js/src/thrift/ConcourseService.js @@ -554,7 +554,7 @@ const ConcourseService_addKeyValueRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp36 = input.readMapBegin(); const _size5 = _rtmp36.size || 0; for (let _i7 = 0; _i7 < _size5; ++_i7) { @@ -562,7 +562,7 @@ const ConcourseService_addKeyValueRecords_result = class { let val9 = null; key8 = input.readI64(); val9 = input.readBool(); - this.success[key8] = val9; + this.success.set(key8, val9); } input.readMapEnd(); } else { @@ -705,7 +705,7 @@ const ConcourseService_auditRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp313 = input.readMapBegin(); const _size12 = _rtmp313.size || 0; for (let _i14 = 0; _i14 < _size12; ++_i14) { @@ -713,7 +713,7 @@ const ConcourseService_auditRecord_result = class { let val16 = null; key15 = input.readI64(); val16 = input.readString(); - this.success[key15] = val16; + this.success.set(key15, val16); } input.readMapEnd(); } else { @@ -857,7 +857,7 @@ const ConcourseService_auditRecordStart_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp320 = input.readMapBegin(); const _size19 = _rtmp320.size || 0; for (let _i21 = 0; _i21 < _size19; ++_i21) { @@ -865,7 +865,7 @@ const ConcourseService_auditRecordStart_result = class { let val23 = null; key22 = input.readI64(); val23 = input.readString(); - this.success[key22] = val23; + this.success.set(key22, val23); } input.readMapEnd(); } else { @@ -1017,7 +1017,7 @@ const ConcourseService_auditRecordStartstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp327 = input.readMapBegin(); const _size26 = _rtmp327.size || 0; for (let _i28 = 0; _i28 < _size26; ++_i28) { @@ -1025,7 +1025,7 @@ const ConcourseService_auditRecordStartstr_result = class { let val30 = null; key29 = input.readI64(); val30 = input.readString(); - this.success[key29] = val30; + this.success.set(key29, val30); } input.readMapEnd(); } else { @@ -1186,7 +1186,7 @@ const ConcourseService_auditRecordStartEnd_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp334 = input.readMapBegin(); const _size33 = _rtmp334.size || 0; for (let _i35 = 0; _i35 < _size33; ++_i35) { @@ -1194,7 +1194,7 @@ const ConcourseService_auditRecordStartEnd_result = class { let val37 = null; key36 = input.readI64(); val37 = input.readString(); - this.success[key36] = val37; + this.success.set(key36, val37); } input.readMapEnd(); } else { @@ -1355,7 +1355,7 @@ const ConcourseService_auditRecordStartstrEndstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp341 = input.readMapBegin(); const _size40 = _rtmp341.size || 0; for (let _i42 = 0; _i42 < _size40; ++_i42) { @@ -1363,7 +1363,7 @@ const ConcourseService_auditRecordStartstrEndstr_result = class { let val44 = null; key43 = input.readI64(); val44 = input.readString(); - this.success[key43] = val44; + this.success.set(key43, val44); } input.readMapEnd(); } else { @@ -1515,7 +1515,7 @@ const ConcourseService_auditKeyRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp348 = input.readMapBegin(); const _size47 = _rtmp348.size || 0; for (let _i49 = 0; _i49 < _size47; ++_i49) { @@ -1523,7 +1523,7 @@ const ConcourseService_auditKeyRecord_result = class { let val51 = null; key50 = input.readI64(); val51 = input.readString(); - this.success[key50] = val51; + this.success.set(key50, val51); } input.readMapEnd(); } else { @@ -1676,7 +1676,7 @@ const ConcourseService_auditKeyRecordStart_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp355 = input.readMapBegin(); const _size54 = _rtmp355.size || 0; for (let _i56 = 0; _i56 < _size54; ++_i56) { @@ -1684,7 +1684,7 @@ const ConcourseService_auditKeyRecordStart_result = class { let val58 = null; key57 = input.readI64(); val58 = input.readString(); - this.success[key57] = val58; + this.success.set(key57, val58); } input.readMapEnd(); } else { @@ -1845,7 +1845,7 @@ const ConcourseService_auditKeyRecordStartstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp362 = input.readMapBegin(); const _size61 = _rtmp362.size || 0; for (let _i63 = 0; _i63 < _size61; ++_i63) { @@ -1853,7 +1853,7 @@ const ConcourseService_auditKeyRecordStartstr_result = class { let val65 = null; key64 = input.readI64(); val65 = input.readString(); - this.success[key64] = val65; + this.success.set(key64, val65); } input.readMapEnd(); } else { @@ -2023,7 +2023,7 @@ const ConcourseService_auditKeyRecordStartEnd_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp369 = input.readMapBegin(); const _size68 = _rtmp369.size || 0; for (let _i70 = 0; _i70 < _size68; ++_i70) { @@ -2031,7 +2031,7 @@ const ConcourseService_auditKeyRecordStartEnd_result = class { let val72 = null; key71 = input.readI64(); val72 = input.readString(); - this.success[key71] = val72; + this.success.set(key71, val72); } input.readMapEnd(); } else { @@ -2201,7 +2201,7 @@ const ConcourseService_auditKeyRecordStartstrEndstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp376 = input.readMapBegin(); const _size75 = _rtmp376.size || 0; for (let _i77 = 0; _i77 < _size75; ++_i77) { @@ -2209,7 +2209,7 @@ const ConcourseService_auditKeyRecordStartstrEndstr_result = class { let val79 = null; key78 = input.readI64(); val79 = input.readString(); - this.success[key78] = val79; + this.success.set(key78, val79); } input.readMapEnd(); } else { @@ -2352,7 +2352,7 @@ const ConcourseService_browseKey_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp383 = input.readMapBegin(); const _size82 = _rtmp383.size || 0; for (let _i84 = 0; _i84 < _size82; ++_i84) { @@ -2369,7 +2369,7 @@ const ConcourseService_browseKey_result = class { val86.push(elem90); } input.readSetEnd(); - this.success[key85] = val86; + this.success.set(key85, val86); } input.readMapEnd(); } else { @@ -2511,14 +2511,14 @@ const ConcourseService_browseKeys_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3100 = input.readMapBegin(); const _size99 = _rtmp3100.size || 0; for (let _i101 = 0; _i101 < _size99; ++_i101) { let key102 = null; let val103 = null; key102 = input.readString(); - val103 = {}; + val103 = new Map(); const _rtmp3105 = input.readMapBegin(); const _size104 = _rtmp3105.size || 0; for (let _i106 = 0; _i106 < _size104; ++_i106) { @@ -2535,10 +2535,10 @@ const ConcourseService_browseKeys_result = class { val108.push(elem112); } input.readSetEnd(); - val103[key107] = val108; + val103.set(key107, val108); } input.readMapEnd(); - this.success[key102] = val103; + this.success.set(key102, val103); } input.readMapEnd(); } else { @@ -2682,7 +2682,7 @@ const ConcourseService_browseKeyTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3119 = input.readMapBegin(); const _size118 = _rtmp3119.size || 0; for (let _i120 = 0; _i120 < _size118; ++_i120) { @@ -2699,7 +2699,7 @@ const ConcourseService_browseKeyTime_result = class { val122.push(elem126); } input.readSetEnd(); - this.success[key121] = val122; + this.success.set(key121, val122); } input.readMapEnd(); } else { @@ -2851,7 +2851,7 @@ const ConcourseService_browseKeyTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3131 = input.readMapBegin(); const _size130 = _rtmp3131.size || 0; for (let _i132 = 0; _i132 < _size130; ++_i132) { @@ -2868,7 +2868,7 @@ const ConcourseService_browseKeyTimestr_result = class { val134.push(elem138); } input.readSetEnd(); - this.success[key133] = val134; + this.success.set(key133, val134); } input.readMapEnd(); } else { @@ -3027,14 +3027,14 @@ const ConcourseService_browseKeysTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3148 = input.readMapBegin(); const _size147 = _rtmp3148.size || 0; for (let _i149 = 0; _i149 < _size147; ++_i149) { let key150 = null; let val151 = null; key150 = input.readString(); - val151 = {}; + val151 = new Map(); const _rtmp3153 = input.readMapBegin(); const _size152 = _rtmp3153.size || 0; for (let _i154 = 0; _i154 < _size152; ++_i154) { @@ -3051,10 +3051,10 @@ const ConcourseService_browseKeysTime_result = class { val156.push(elem160); } input.readSetEnd(); - val151[key155] = val156; + val151.set(key155, val156); } input.readMapEnd(); - this.success[key150] = val151; + this.success.set(key150, val151); } input.readMapEnd(); } else { @@ -3213,14 +3213,14 @@ const ConcourseService_browseKeysTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3172 = input.readMapBegin(); const _size171 = _rtmp3172.size || 0; for (let _i173 = 0; _i173 < _size171; ++_i173) { let key174 = null; let val175 = null; key174 = input.readString(); - val175 = {}; + val175 = new Map(); const _rtmp3177 = input.readMapBegin(); const _size176 = _rtmp3177.size || 0; for (let _i178 = 0; _i178 < _size176; ++_i178) { @@ -3237,10 +3237,10 @@ const ConcourseService_browseKeysTimestr_result = class { val180.push(elem184); } input.readSetEnd(); - val175[key179] = val180; + val175.set(key179, val180); } input.readMapEnd(); - this.success[key174] = val175; + this.success.set(key174, val175); } input.readMapEnd(); } else { @@ -3392,7 +3392,7 @@ const ConcourseService_chronologizeKeyRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3191 = input.readMapBegin(); const _size190 = _rtmp3191.size || 0; for (let _i192 = 0; _i192 < _size190; ++_i192) { @@ -3409,7 +3409,7 @@ const ConcourseService_chronologizeKeyRecord_result = class { val194.push(elem198); } input.readSetEnd(); - this.success[key193] = val194; + this.success.set(key193, val194); } input.readMapEnd(); } else { @@ -3562,7 +3562,7 @@ const ConcourseService_chronologizeKeyRecordStart_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3203 = input.readMapBegin(); const _size202 = _rtmp3203.size || 0; for (let _i204 = 0; _i204 < _size202; ++_i204) { @@ -3579,7 +3579,7 @@ const ConcourseService_chronologizeKeyRecordStart_result = class { val206.push(elem210); } input.readSetEnd(); - this.success[key205] = val206; + this.success.set(key205, val206); } input.readMapEnd(); } else { @@ -3740,7 +3740,7 @@ const ConcourseService_chronologizeKeyRecordStartstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3215 = input.readMapBegin(); const _size214 = _rtmp3215.size || 0; for (let _i216 = 0; _i216 < _size214; ++_i216) { @@ -3757,7 +3757,7 @@ const ConcourseService_chronologizeKeyRecordStartstr_result = class { val218.push(elem222); } input.readSetEnd(); - this.success[key217] = val218; + this.success.set(key217, val218); } input.readMapEnd(); } else { @@ -3927,7 +3927,7 @@ const ConcourseService_chronologizeKeyRecordStartEnd_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3227 = input.readMapBegin(); const _size226 = _rtmp3227.size || 0; for (let _i228 = 0; _i228 < _size226; ++_i228) { @@ -3944,7 +3944,7 @@ const ConcourseService_chronologizeKeyRecordStartEnd_result = class { val230.push(elem234); } input.readSetEnd(); - this.success[key229] = val230; + this.success.set(key229, val230); } input.readMapEnd(); } else { @@ -4114,7 +4114,7 @@ const ConcourseService_chronologizeKeyRecordStartstrEndstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3239 = input.readMapBegin(); const _size238 = _rtmp3239.size || 0; for (let _i240 = 0; _i240 < _size238; ++_i240) { @@ -4131,7 +4131,7 @@ const ConcourseService_chronologizeKeyRecordStartstrEndstr_result = class { val242.push(elem246); } input.readSetEnd(); - this.success[key241] = val242; + this.success.set(key241, val242); } input.readMapEnd(); } else { @@ -6079,7 +6079,7 @@ const ConcourseService_describeRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3311 = input.readMapBegin(); const _size310 = _rtmp3311.size || 0; for (let _i312 = 0; _i312 < _size310; ++_i312) { @@ -6095,7 +6095,7 @@ const ConcourseService_describeRecords_result = class { val314.push(elem318); } input.readSetEnd(); - this.success[key313] = val314; + this.success.set(key313, val314); } input.readMapEnd(); } else { @@ -6246,7 +6246,7 @@ const ConcourseService_describeRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3328 = input.readMapBegin(); const _size327 = _rtmp3328.size || 0; for (let _i329 = 0; _i329 < _size327; ++_i329) { @@ -6262,7 +6262,7 @@ const ConcourseService_describeRecordsTime_result = class { val331.push(elem335); } input.readSetEnd(); - this.success[key330] = val331; + this.success.set(key330, val331); } input.readMapEnd(); } else { @@ -6421,7 +6421,7 @@ const ConcourseService_describeRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3345 = input.readMapBegin(); const _size344 = _rtmp3345.size || 0; for (let _i346 = 0; _i346 < _size344; ++_i346) { @@ -6437,7 +6437,7 @@ const ConcourseService_describeRecordsTimestr_result = class { val348.push(elem352); } input.readSetEnd(); - this.success[key347] = val348; + this.success.set(key347, val348); } input.readMapEnd(); } else { @@ -6589,14 +6589,14 @@ const ConcourseService_diffRecordStart_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3357 = input.readMapBegin(); const _size356 = _rtmp3357.size || 0; for (let _i358 = 0; _i358 < _size356; ++_i358) { let key359 = null; let val360 = null; key359 = input.readString(); - val360 = {}; + val360 = new Map(); const _rtmp3362 = input.readMapBegin(); const _size361 = _rtmp3362.size || 0; for (let _i363 = 0; _i363 < _size361; ++_i363) { @@ -6613,10 +6613,10 @@ const ConcourseService_diffRecordStart_result = class { val365.push(elem369); } input.readSetEnd(); - val360[key364] = val365; + val360.set(key364, val365); } input.readMapEnd(); - this.success[key359] = val360; + this.success.set(key359, val360); } input.readMapEnd(); } else { @@ -6768,14 +6768,14 @@ const ConcourseService_diffRecordStartstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3376 = input.readMapBegin(); const _size375 = _rtmp3376.size || 0; for (let _i377 = 0; _i377 < _size375; ++_i377) { let key378 = null; let val379 = null; key378 = input.readString(); - val379 = {}; + val379 = new Map(); const _rtmp3381 = input.readMapBegin(); const _size380 = _rtmp3381.size || 0; for (let _i382 = 0; _i382 < _size380; ++_i382) { @@ -6792,10 +6792,10 @@ const ConcourseService_diffRecordStartstr_result = class { val384.push(elem388); } input.readSetEnd(); - val379[key383] = val384; + val379.set(key383, val384); } input.readMapEnd(); - this.success[key378] = val379; + this.success.set(key378, val379); } input.readMapEnd(); } else { @@ -6956,14 +6956,14 @@ const ConcourseService_diffRecordStartEnd_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3395 = input.readMapBegin(); const _size394 = _rtmp3395.size || 0; for (let _i396 = 0; _i396 < _size394; ++_i396) { let key397 = null; let val398 = null; key397 = input.readString(); - val398 = {}; + val398 = new Map(); const _rtmp3400 = input.readMapBegin(); const _size399 = _rtmp3400.size || 0; for (let _i401 = 0; _i401 < _size399; ++_i401) { @@ -6980,10 +6980,10 @@ const ConcourseService_diffRecordStartEnd_result = class { val403.push(elem407); } input.readSetEnd(); - val398[key402] = val403; + val398.set(key402, val403); } input.readMapEnd(); - this.success[key397] = val398; + this.success.set(key397, val398); } input.readMapEnd(); } else { @@ -7144,14 +7144,14 @@ const ConcourseService_diffRecordStartstrEndstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3414 = input.readMapBegin(); const _size413 = _rtmp3414.size || 0; for (let _i415 = 0; _i415 < _size413; ++_i415) { let key416 = null; let val417 = null; key416 = input.readString(); - val417 = {}; + val417 = new Map(); const _rtmp3419 = input.readMapBegin(); const _size418 = _rtmp3419.size || 0; for (let _i420 = 0; _i420 < _size418; ++_i420) { @@ -7168,10 +7168,10 @@ const ConcourseService_diffRecordStartstrEndstr_result = class { val422.push(elem426); } input.readSetEnd(); - val417[key421] = val422; + val417.set(key421, val422); } input.readMapEnd(); - this.success[key416] = val417; + this.success.set(key416, val417); } input.readMapEnd(); } else { @@ -7332,7 +7332,7 @@ const ConcourseService_diffKeyRecordStart_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3433 = input.readMapBegin(); const _size432 = _rtmp3433.size || 0; for (let _i434 = 0; _i434 < _size432; ++_i434) { @@ -7349,7 +7349,7 @@ const ConcourseService_diffKeyRecordStart_result = class { val436.push(elem440); } input.readSetEnd(); - this.success[key435] = val436; + this.success.set(key435, val436); } input.readMapEnd(); } else { @@ -7510,7 +7510,7 @@ const ConcourseService_diffKeyRecordStartstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3445 = input.readMapBegin(); const _size444 = _rtmp3445.size || 0; for (let _i446 = 0; _i446 < _size444; ++_i446) { @@ -7527,7 +7527,7 @@ const ConcourseService_diffKeyRecordStartstr_result = class { val448.push(elem452); } input.readSetEnd(); - this.success[key447] = val448; + this.success.set(key447, val448); } input.readMapEnd(); } else { @@ -7697,7 +7697,7 @@ const ConcourseService_diffKeyRecordStartEnd_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3457 = input.readMapBegin(); const _size456 = _rtmp3457.size || 0; for (let _i458 = 0; _i458 < _size456; ++_i458) { @@ -7714,7 +7714,7 @@ const ConcourseService_diffKeyRecordStartEnd_result = class { val460.push(elem464); } input.readSetEnd(); - this.success[key459] = val460; + this.success.set(key459, val460); } input.readMapEnd(); } else { @@ -7884,7 +7884,7 @@ const ConcourseService_diffKeyRecordStartstrEndstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3469 = input.readMapBegin(); const _size468 = _rtmp3469.size || 0; for (let _i470 = 0; _i470 < _size468; ++_i470) { @@ -7901,7 +7901,7 @@ const ConcourseService_diffKeyRecordStartstrEndstr_result = class { val472.push(elem476); } input.readSetEnd(); - this.success[key471] = val472; + this.success.set(key471, val472); } input.readMapEnd(); } else { @@ -8053,7 +8053,7 @@ const ConcourseService_diffKeyStart_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3481 = input.readMapBegin(); const _size480 = _rtmp3481.size || 0; for (let _i482 = 0; _i482 < _size480; ++_i482) { @@ -8061,7 +8061,7 @@ const ConcourseService_diffKeyStart_result = class { let val484 = null; key483 = new data_ttypes.TObject(); key483.read(input); - val484 = {}; + val484 = new Map(); const _rtmp3486 = input.readMapBegin(); const _size485 = _rtmp3486.size || 0; for (let _i487 = 0; _i487 < _size485; ++_i487) { @@ -8077,10 +8077,10 @@ const ConcourseService_diffKeyStart_result = class { val489.push(elem493); } input.readSetEnd(); - val484[key488] = val489; + val484.set(key488, val489); } input.readMapEnd(); - this.success[key483] = val484; + this.success.set(key483, val484); } input.readMapEnd(); } else { @@ -8232,7 +8232,7 @@ const ConcourseService_diffKeyStartstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3500 = input.readMapBegin(); const _size499 = _rtmp3500.size || 0; for (let _i501 = 0; _i501 < _size499; ++_i501) { @@ -8240,7 +8240,7 @@ const ConcourseService_diffKeyStartstr_result = class { let val503 = null; key502 = new data_ttypes.TObject(); key502.read(input); - val503 = {}; + val503 = new Map(); const _rtmp3505 = input.readMapBegin(); const _size504 = _rtmp3505.size || 0; for (let _i506 = 0; _i506 < _size504; ++_i506) { @@ -8256,10 +8256,10 @@ const ConcourseService_diffKeyStartstr_result = class { val508.push(elem512); } input.readSetEnd(); - val503[key507] = val508; + val503.set(key507, val508); } input.readMapEnd(); - this.success[key502] = val503; + this.success.set(key502, val503); } input.readMapEnd(); } else { @@ -8420,7 +8420,7 @@ const ConcourseService_diffKeyStartEnd_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3519 = input.readMapBegin(); const _size518 = _rtmp3519.size || 0; for (let _i520 = 0; _i520 < _size518; ++_i520) { @@ -8428,7 +8428,7 @@ const ConcourseService_diffKeyStartEnd_result = class { let val522 = null; key521 = new data_ttypes.TObject(); key521.read(input); - val522 = {}; + val522 = new Map(); const _rtmp3524 = input.readMapBegin(); const _size523 = _rtmp3524.size || 0; for (let _i525 = 0; _i525 < _size523; ++_i525) { @@ -8444,10 +8444,10 @@ const ConcourseService_diffKeyStartEnd_result = class { val527.push(elem531); } input.readSetEnd(); - val522[key526] = val527; + val522.set(key526, val527); } input.readMapEnd(); - this.success[key521] = val522; + this.success.set(key521, val522); } input.readMapEnd(); } else { @@ -8608,7 +8608,7 @@ const ConcourseService_diffKeyStartstrEndstr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3538 = input.readMapBegin(); const _size537 = _rtmp3538.size || 0; for (let _i539 = 0; _i539 < _size537; ++_i539) { @@ -8616,7 +8616,7 @@ const ConcourseService_diffKeyStartstrEndstr_result = class { let val541 = null; key540 = new data_ttypes.TObject(); key540.read(input); - val541 = {}; + val541 = new Map(); const _rtmp3543 = input.readMapBegin(); const _size542 = _rtmp3543.size || 0; for (let _i544 = 0; _i544 < _size542; ++_i544) { @@ -8632,10 +8632,10 @@ const ConcourseService_diffKeyStartstrEndstr_result = class { val546.push(elem550); } input.readSetEnd(); - val541[key545] = val546; + val541.set(key545, val546); } input.readMapEnd(); - this.success[key540] = val541; + this.success.set(key540, val541); } input.readMapEnd(); } else { @@ -9629,7 +9629,7 @@ const ConcourseService_insertJsonRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3572 = input.readMapBegin(); const _size571 = _rtmp3572.size || 0; for (let _i573 = 0; _i573 < _size571; ++_i573) { @@ -9637,7 +9637,7 @@ const ConcourseService_insertJsonRecords_result = class { let val575 = null; key574 = input.readI64(); val575 = input.readBool(); - this.success[key574] = val575; + this.success.set(key574, val575); } input.readMapEnd(); } else { @@ -9988,7 +9988,7 @@ const ConcourseService_removeKeyValueRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3584 = input.readMapBegin(); const _size583 = _rtmp3584.size || 0; for (let _i585 = 0; _i585 < _size583; ++_i585) { @@ -9996,7 +9996,7 @@ const ConcourseService_removeKeyValueRecords_result = class { let val587 = null; key586 = input.readI64(); val587 = input.readBool(); - this.success[key586] = val587; + this.success.set(key586, val587); } input.readMapEnd(); } else { @@ -10911,7 +10911,7 @@ const ConcourseService_selectRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3606 = input.readMapBegin(); const _size605 = _rtmp3606.size || 0; for (let _i607 = 0; _i607 < _size605; ++_i607) { @@ -10928,7 +10928,7 @@ const ConcourseService_selectRecord_result = class { val609.push(elem613); } input.readSetEnd(); - this.success[key608] = val609; + this.success.set(key608, val609); } input.readMapEnd(); } else { @@ -11070,14 +11070,14 @@ const ConcourseService_selectRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3623 = input.readMapBegin(); const _size622 = _rtmp3623.size || 0; for (let _i624 = 0; _i624 < _size622; ++_i624) { let key625 = null; let val626 = null; key625 = input.readI64(); - val626 = {}; + val626 = new Map(); const _rtmp3628 = input.readMapBegin(); const _size627 = _rtmp3628.size || 0; for (let _i629 = 0; _i629 < _size627; ++_i629) { @@ -11094,10 +11094,10 @@ const ConcourseService_selectRecords_result = class { val631.push(elem635); } input.readSetEnd(); - val626[key630] = val631; + val626.set(key630, val631); } input.readMapEnd(); - this.success[key625] = val626; + this.success.set(key625, val626); } input.readMapEnd(); } else { @@ -11241,7 +11241,7 @@ const ConcourseService_selectRecordTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3642 = input.readMapBegin(); const _size641 = _rtmp3642.size || 0; for (let _i643 = 0; _i643 < _size641; ++_i643) { @@ -11258,7 +11258,7 @@ const ConcourseService_selectRecordTime_result = class { val645.push(elem649); } input.readSetEnd(); - this.success[key644] = val645; + this.success.set(key644, val645); } input.readMapEnd(); } else { @@ -11410,7 +11410,7 @@ const ConcourseService_selectRecordTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3654 = input.readMapBegin(); const _size653 = _rtmp3654.size || 0; for (let _i655 = 0; _i655 < _size653; ++_i655) { @@ -11427,7 +11427,7 @@ const ConcourseService_selectRecordTimestr_result = class { val657.push(elem661); } input.readSetEnd(); - this.success[key656] = val657; + this.success.set(key656, val657); } input.readMapEnd(); } else { @@ -11586,14 +11586,14 @@ const ConcourseService_selectRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3671 = input.readMapBegin(); const _size670 = _rtmp3671.size || 0; for (let _i672 = 0; _i672 < _size670; ++_i672) { let key673 = null; let val674 = null; key673 = input.readI64(); - val674 = {}; + val674 = new Map(); const _rtmp3676 = input.readMapBegin(); const _size675 = _rtmp3676.size || 0; for (let _i677 = 0; _i677 < _size675; ++_i677) { @@ -11610,10 +11610,10 @@ const ConcourseService_selectRecordsTime_result = class { val679.push(elem683); } input.readSetEnd(); - val674[key678] = val679; + val674.set(key678, val679); } input.readMapEnd(); - this.success[key673] = val674; + this.success.set(key673, val674); } input.readMapEnd(); } else { @@ -11772,14 +11772,14 @@ const ConcourseService_selectRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3695 = input.readMapBegin(); const _size694 = _rtmp3695.size || 0; for (let _i696 = 0; _i696 < _size694; ++_i696) { let key697 = null; let val698 = null; key697 = input.readI64(); - val698 = {}; + val698 = new Map(); const _rtmp3700 = input.readMapBegin(); const _size699 = _rtmp3700.size || 0; for (let _i701 = 0; _i701 < _size699; ++_i701) { @@ -11796,10 +11796,10 @@ const ConcourseService_selectRecordsTimestr_result = class { val703.push(elem707); } input.readSetEnd(); - val698[key702] = val703; + val698.set(key702, val703); } input.readMapEnd(); - this.success[key697] = val698; + this.success.set(key697, val698); } input.readMapEnd(); } else { @@ -12445,7 +12445,7 @@ const ConcourseService_selectKeysRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3734 = input.readMapBegin(); const _size733 = _rtmp3734.size || 0; for (let _i735 = 0; _i735 < _size733; ++_i735) { @@ -12462,7 +12462,7 @@ const ConcourseService_selectKeysRecord_result = class { val737.push(elem741); } input.readSetEnd(); - this.success[key736] = val737; + this.success.set(key736, val737); } input.readMapEnd(); } else { @@ -12622,7 +12622,7 @@ const ConcourseService_selectKeysRecordTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3751 = input.readMapBegin(); const _size750 = _rtmp3751.size || 0; for (let _i752 = 0; _i752 < _size750; ++_i752) { @@ -12639,7 +12639,7 @@ const ConcourseService_selectKeysRecordTime_result = class { val754.push(elem758); } input.readSetEnd(); - this.success[key753] = val754; + this.success.set(key753, val754); } input.readMapEnd(); } else { @@ -12807,7 +12807,7 @@ const ConcourseService_selectKeysRecordTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3768 = input.readMapBegin(); const _size767 = _rtmp3768.size || 0; for (let _i769 = 0; _i769 < _size767; ++_i769) { @@ -12824,7 +12824,7 @@ const ConcourseService_selectKeysRecordTimestr_result = class { val771.push(elem775); } input.readSetEnd(); - this.success[key770] = val771; + this.success.set(key770, val771); } input.readMapEnd(); } else { @@ -12990,14 +12990,14 @@ const ConcourseService_selectKeysRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3790 = input.readMapBegin(); const _size789 = _rtmp3790.size || 0; for (let _i791 = 0; _i791 < _size789; ++_i791) { let key792 = null; let val793 = null; key792 = input.readI64(); - val793 = {}; + val793 = new Map(); const _rtmp3795 = input.readMapBegin(); const _size794 = _rtmp3795.size || 0; for (let _i796 = 0; _i796 < _size794; ++_i796) { @@ -13014,10 +13014,10 @@ const ConcourseService_selectKeysRecords_result = class { val798.push(elem802); } input.readSetEnd(); - val793[key797] = val798; + val793.set(key797, val798); } input.readMapEnd(); - this.success[key792] = val793; + this.success.set(key792, val793); } input.readMapEnd(); } else { @@ -13168,7 +13168,7 @@ const ConcourseService_selectKeyRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3814 = input.readMapBegin(); const _size813 = _rtmp3814.size || 0; for (let _i815 = 0; _i815 < _size813; ++_i815) { @@ -13185,7 +13185,7 @@ const ConcourseService_selectKeyRecords_result = class { val817.push(elem821); } input.readSetEnd(); - this.success[key816] = val817; + this.success.set(key816, val817); } input.readMapEnd(); } else { @@ -13345,7 +13345,7 @@ const ConcourseService_selectKeyRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3831 = input.readMapBegin(); const _size830 = _rtmp3831.size || 0; for (let _i832 = 0; _i832 < _size830; ++_i832) { @@ -13362,7 +13362,7 @@ const ConcourseService_selectKeyRecordsTime_result = class { val834.push(elem838); } input.readSetEnd(); - this.success[key833] = val834; + this.success.set(key833, val834); } input.readMapEnd(); } else { @@ -13530,7 +13530,7 @@ const ConcourseService_selectKeyRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3848 = input.readMapBegin(); const _size847 = _rtmp3848.size || 0; for (let _i849 = 0; _i849 < _size847; ++_i849) { @@ -13547,7 +13547,7 @@ const ConcourseService_selectKeyRecordsTimestr_result = class { val851.push(elem855); } input.readSetEnd(); - this.success[key850] = val851; + this.success.set(key850, val851); } input.readMapEnd(); } else { @@ -13722,14 +13722,14 @@ const ConcourseService_selectKeysRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3870 = input.readMapBegin(); const _size869 = _rtmp3870.size || 0; for (let _i871 = 0; _i871 < _size869; ++_i871) { let key872 = null; let val873 = null; key872 = input.readI64(); - val873 = {}; + val873 = new Map(); const _rtmp3875 = input.readMapBegin(); const _size874 = _rtmp3875.size || 0; for (let _i876 = 0; _i876 < _size874; ++_i876) { @@ -13746,10 +13746,10 @@ const ConcourseService_selectKeysRecordsTime_result = class { val878.push(elem882); } input.readSetEnd(); - val873[key877] = val878; + val873.set(key877, val878); } input.readMapEnd(); - this.success[key872] = val873; + this.success.set(key872, val873); } input.readMapEnd(); } else { @@ -13924,14 +13924,14 @@ const ConcourseService_selectKeysRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3899 = input.readMapBegin(); const _size898 = _rtmp3899.size || 0; for (let _i900 = 0; _i900 < _size898; ++_i900) { let key901 = null; let val902 = null; key901 = input.readI64(); - val902 = {}; + val902 = new Map(); const _rtmp3904 = input.readMapBegin(); const _size903 = _rtmp3904.size || 0; for (let _i905 = 0; _i905 < _size903; ++_i905) { @@ -13948,10 +13948,10 @@ const ConcourseService_selectKeysRecordsTimestr_result = class { val907.push(elem911); } input.readSetEnd(); - val902[key906] = val907; + val902.set(key906, val907); } input.readMapEnd(); - this.success[key901] = val902; + this.success.set(key901, val902); } input.readMapEnd(); } else { @@ -14094,14 +14094,14 @@ const ConcourseService_selectCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3918 = input.readMapBegin(); const _size917 = _rtmp3918.size || 0; for (let _i919 = 0; _i919 < _size917; ++_i919) { let key920 = null; let val921 = null; key920 = input.readI64(); - val921 = {}; + val921 = new Map(); const _rtmp3923 = input.readMapBegin(); const _size922 = _rtmp3923.size || 0; for (let _i924 = 0; _i924 < _size922; ++_i924) { @@ -14118,10 +14118,10 @@ const ConcourseService_selectCriteria_result = class { val926.push(elem930); } input.readSetEnd(); - val921[key925] = val926; + val921.set(key925, val926); } input.readMapEnd(); - this.success[key920] = val921; + this.success.set(key920, val921); } input.readMapEnd(); } else { @@ -14264,14 +14264,14 @@ const ConcourseService_selectCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3937 = input.readMapBegin(); const _size936 = _rtmp3937.size || 0; for (let _i938 = 0; _i938 < _size936; ++_i938) { let key939 = null; let val940 = null; key939 = input.readI64(); - val940 = {}; + val940 = new Map(); const _rtmp3942 = input.readMapBegin(); const _size941 = _rtmp3942.size || 0; for (let _i943 = 0; _i943 < _size941; ++_i943) { @@ -14288,10 +14288,10 @@ const ConcourseService_selectCcl_result = class { val945.push(elem949); } input.readSetEnd(); - val940[key944] = val945; + val940.set(key944, val945); } input.readMapEnd(); - this.success[key939] = val940; + this.success.set(key939, val940); } input.readMapEnd(); } else { @@ -14443,14 +14443,14 @@ const ConcourseService_selectCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3956 = input.readMapBegin(); const _size955 = _rtmp3956.size || 0; for (let _i957 = 0; _i957 < _size955; ++_i957) { let key958 = null; let val959 = null; key958 = input.readI64(); - val959 = {}; + val959 = new Map(); const _rtmp3961 = input.readMapBegin(); const _size960 = _rtmp3961.size || 0; for (let _i962 = 0; _i962 < _size960; ++_i962) { @@ -14467,10 +14467,10 @@ const ConcourseService_selectCriteriaTime_result = class { val964.push(elem968); } input.readSetEnd(); - val959[key963] = val964; + val959.set(key963, val964); } input.readMapEnd(); - this.success[key958] = val959; + this.success.set(key958, val959); } input.readMapEnd(); } else { @@ -14622,14 +14622,14 @@ const ConcourseService_selectCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3975 = input.readMapBegin(); const _size974 = _rtmp3975.size || 0; for (let _i976 = 0; _i976 < _size974; ++_i976) { let key977 = null; let val978 = null; key977 = input.readI64(); - val978 = {}; + val978 = new Map(); const _rtmp3980 = input.readMapBegin(); const _size979 = _rtmp3980.size || 0; for (let _i981 = 0; _i981 < _size979; ++_i981) { @@ -14646,10 +14646,10 @@ const ConcourseService_selectCriteriaTimestr_result = class { val983.push(elem987); } input.readSetEnd(); - val978[key982] = val983; + val978.set(key982, val983); } input.readMapEnd(); - this.success[key977] = val978; + this.success.set(key977, val978); } input.readMapEnd(); } else { @@ -14809,14 +14809,14 @@ const ConcourseService_selectCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp3994 = input.readMapBegin(); const _size993 = _rtmp3994.size || 0; for (let _i995 = 0; _i995 < _size993; ++_i995) { let key996 = null; let val997 = null; key996 = input.readI64(); - val997 = {}; + val997 = new Map(); const _rtmp3999 = input.readMapBegin(); const _size998 = _rtmp3999.size || 0; for (let _i1000 = 0; _i1000 < _size998; ++_i1000) { @@ -14833,10 +14833,10 @@ const ConcourseService_selectCclTime_result = class { val1002.push(elem1006); } input.readSetEnd(); - val997[key1001] = val1002; + val997.set(key1001, val1002); } input.readMapEnd(); - this.success[key996] = val997; + this.success.set(key996, val997); } input.readMapEnd(); } else { @@ -14996,14 +14996,14 @@ const ConcourseService_selectCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31013 = input.readMapBegin(); const _size1012 = _rtmp31013.size || 0; for (let _i1014 = 0; _i1014 < _size1012; ++_i1014) { let key1015 = null; let val1016 = null; key1015 = input.readI64(); - val1016 = {}; + val1016 = new Map(); const _rtmp31018 = input.readMapBegin(); const _size1017 = _rtmp31018.size || 0; for (let _i1019 = 0; _i1019 < _size1017; ++_i1019) { @@ -15020,10 +15020,10 @@ const ConcourseService_selectCclTimestr_result = class { val1021.push(elem1025); } input.readSetEnd(); - val1016[key1020] = val1021; + val1016.set(key1020, val1021); } input.readMapEnd(); - this.success[key1015] = val1016; + this.success.set(key1015, val1016); } input.readMapEnd(); } else { @@ -15175,7 +15175,7 @@ const ConcourseService_selectKeyCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31032 = input.readMapBegin(); const _size1031 = _rtmp31032.size || 0; for (let _i1033 = 0; _i1033 < _size1031; ++_i1033) { @@ -15192,7 +15192,7 @@ const ConcourseService_selectKeyCriteria_result = class { val1035.push(elem1039); } input.readSetEnd(); - this.success[key1034] = val1035; + this.success.set(key1034, val1035); } input.readMapEnd(); } else { @@ -15344,7 +15344,7 @@ const ConcourseService_selectKeyCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31044 = input.readMapBegin(); const _size1043 = _rtmp31044.size || 0; for (let _i1045 = 0; _i1045 < _size1043; ++_i1045) { @@ -15361,7 +15361,7 @@ const ConcourseService_selectKeyCcl_result = class { val1047.push(elem1051); } input.readSetEnd(); - this.success[key1046] = val1047; + this.success.set(key1046, val1047); } input.readMapEnd(); } else { @@ -15522,7 +15522,7 @@ const ConcourseService_selectKeyCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31056 = input.readMapBegin(); const _size1055 = _rtmp31056.size || 0; for (let _i1057 = 0; _i1057 < _size1055; ++_i1057) { @@ -15539,7 +15539,7 @@ const ConcourseService_selectKeyCriteriaTime_result = class { val1059.push(elem1063); } input.readSetEnd(); - this.success[key1058] = val1059; + this.success.set(key1058, val1059); } input.readMapEnd(); } else { @@ -15700,7 +15700,7 @@ const ConcourseService_selectKeyCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31068 = input.readMapBegin(); const _size1067 = _rtmp31068.size || 0; for (let _i1069 = 0; _i1069 < _size1067; ++_i1069) { @@ -15717,7 +15717,7 @@ const ConcourseService_selectKeyCriteriaTimestr_result = class { val1071.push(elem1075); } input.readSetEnd(); - this.success[key1070] = val1071; + this.success.set(key1070, val1071); } input.readMapEnd(); } else { @@ -15886,7 +15886,7 @@ const ConcourseService_selectKeyCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31080 = input.readMapBegin(); const _size1079 = _rtmp31080.size || 0; for (let _i1081 = 0; _i1081 < _size1079; ++_i1081) { @@ -15903,7 +15903,7 @@ const ConcourseService_selectKeyCclTime_result = class { val1083.push(elem1087); } input.readSetEnd(); - this.success[key1082] = val1083; + this.success.set(key1082, val1083); } input.readMapEnd(); } else { @@ -16072,7 +16072,7 @@ const ConcourseService_selectKeyCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31092 = input.readMapBegin(); const _size1091 = _rtmp31092.size || 0; for (let _i1093 = 0; _i1093 < _size1091; ++_i1093) { @@ -16089,7 +16089,7 @@ const ConcourseService_selectKeyCclTimestr_result = class { val1095.push(elem1099); } input.readSetEnd(); - this.success[key1094] = val1095; + this.success.set(key1094, val1095); } input.readMapEnd(); } else { @@ -16248,14 +16248,14 @@ const ConcourseService_selectKeysCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31109 = input.readMapBegin(); const _size1108 = _rtmp31109.size || 0; for (let _i1110 = 0; _i1110 < _size1108; ++_i1110) { let key1111 = null; let val1112 = null; key1111 = input.readI64(); - val1112 = {}; + val1112 = new Map(); const _rtmp31114 = input.readMapBegin(); const _size1113 = _rtmp31114.size || 0; for (let _i1115 = 0; _i1115 < _size1113; ++_i1115) { @@ -16272,10 +16272,10 @@ const ConcourseService_selectKeysCriteria_result = class { val1117.push(elem1121); } input.readSetEnd(); - val1112[key1116] = val1117; + val1112.set(key1116, val1117); } input.readMapEnd(); - this.success[key1111] = val1112; + this.success.set(key1111, val1112); } input.readMapEnd(); } else { @@ -16434,14 +16434,14 @@ const ConcourseService_selectKeysCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31133 = input.readMapBegin(); const _size1132 = _rtmp31133.size || 0; for (let _i1134 = 0; _i1134 < _size1132; ++_i1134) { let key1135 = null; let val1136 = null; key1135 = input.readI64(); - val1136 = {}; + val1136 = new Map(); const _rtmp31138 = input.readMapBegin(); const _size1137 = _rtmp31138.size || 0; for (let _i1139 = 0; _i1139 < _size1137; ++_i1139) { @@ -16458,10 +16458,10 @@ const ConcourseService_selectKeysCcl_result = class { val1141.push(elem1145); } input.readSetEnd(); - val1136[key1140] = val1141; + val1136.set(key1140, val1141); } input.readMapEnd(); - this.success[key1135] = val1136; + this.success.set(key1135, val1136); } input.readMapEnd(); } else { @@ -16629,14 +16629,14 @@ const ConcourseService_selectKeysCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31157 = input.readMapBegin(); const _size1156 = _rtmp31157.size || 0; for (let _i1158 = 0; _i1158 < _size1156; ++_i1158) { let key1159 = null; let val1160 = null; key1159 = input.readI64(); - val1160 = {}; + val1160 = new Map(); const _rtmp31162 = input.readMapBegin(); const _size1161 = _rtmp31162.size || 0; for (let _i1163 = 0; _i1163 < _size1161; ++_i1163) { @@ -16653,10 +16653,10 @@ const ConcourseService_selectKeysCriteriaTime_result = class { val1165.push(elem1169); } input.readSetEnd(); - val1160[key1164] = val1165; + val1160.set(key1164, val1165); } input.readMapEnd(); - this.success[key1159] = val1160; + this.success.set(key1159, val1160); } input.readMapEnd(); } else { @@ -16824,14 +16824,14 @@ const ConcourseService_selectKeysCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31181 = input.readMapBegin(); const _size1180 = _rtmp31181.size || 0; for (let _i1182 = 0; _i1182 < _size1180; ++_i1182) { let key1183 = null; let val1184 = null; key1183 = input.readI64(); - val1184 = {}; + val1184 = new Map(); const _rtmp31186 = input.readMapBegin(); const _size1185 = _rtmp31186.size || 0; for (let _i1187 = 0; _i1187 < _size1185; ++_i1187) { @@ -16848,10 +16848,10 @@ const ConcourseService_selectKeysCriteriaTimestr_result = class { val1189.push(elem1193); } input.readSetEnd(); - val1184[key1188] = val1189; + val1184.set(key1188, val1189); } input.readMapEnd(); - this.success[key1183] = val1184; + this.success.set(key1183, val1184); } input.readMapEnd(); } else { @@ -17027,14 +17027,14 @@ const ConcourseService_selectKeysCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31205 = input.readMapBegin(); const _size1204 = _rtmp31205.size || 0; for (let _i1206 = 0; _i1206 < _size1204; ++_i1206) { let key1207 = null; let val1208 = null; key1207 = input.readI64(); - val1208 = {}; + val1208 = new Map(); const _rtmp31210 = input.readMapBegin(); const _size1209 = _rtmp31210.size || 0; for (let _i1211 = 0; _i1211 < _size1209; ++_i1211) { @@ -17051,10 +17051,10 @@ const ConcourseService_selectKeysCclTime_result = class { val1213.push(elem1217); } input.readSetEnd(); - val1208[key1212] = val1213; + val1208.set(key1212, val1213); } input.readMapEnd(); - this.success[key1207] = val1208; + this.success.set(key1207, val1208); } input.readMapEnd(); } else { @@ -17230,14 +17230,14 @@ const ConcourseService_selectKeysCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31229 = input.readMapBegin(); const _size1228 = _rtmp31229.size || 0; for (let _i1230 = 0; _i1230 < _size1228; ++_i1230) { let key1231 = null; let val1232 = null; key1231 = input.readI64(); - val1232 = {}; + val1232 = new Map(); const _rtmp31234 = input.readMapBegin(); const _size1233 = _rtmp31234.size || 0; for (let _i1235 = 0; _i1235 < _size1233; ++_i1235) { @@ -17254,10 +17254,10 @@ const ConcourseService_selectKeysCclTimestr_result = class { val1237.push(elem1241); } input.readSetEnd(); - val1232[key1236] = val1237; + val1232.set(key1236, val1237); } input.readMapEnd(); - this.success[key1231] = val1232; + this.success.set(key1231, val1232); } input.readMapEnd(); } else { @@ -17879,7 +17879,7 @@ const ConcourseService_getKeysRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31253 = input.readMapBegin(); const _size1252 = _rtmp31253.size || 0; for (let _i1254 = 0; _i1254 < _size1252; ++_i1254) { @@ -17888,7 +17888,7 @@ const ConcourseService_getKeysRecord_result = class { key1255 = input.readString(); val1256 = new data_ttypes.TObject(); val1256.read(input); - this.success[key1255] = val1256; + this.success.set(key1255, val1256); } input.readMapEnd(); } else { @@ -18048,7 +18048,7 @@ const ConcourseService_getKeysRecordTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31265 = input.readMapBegin(); const _size1264 = _rtmp31265.size || 0; for (let _i1266 = 0; _i1266 < _size1264; ++_i1266) { @@ -18057,7 +18057,7 @@ const ConcourseService_getKeysRecordTime_result = class { key1267 = input.readString(); val1268 = new data_ttypes.TObject(); val1268.read(input); - this.success[key1267] = val1268; + this.success.set(key1267, val1268); } input.readMapEnd(); } else { @@ -18225,7 +18225,7 @@ const ConcourseService_getKeysRecordTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31277 = input.readMapBegin(); const _size1276 = _rtmp31277.size || 0; for (let _i1278 = 0; _i1278 < _size1276; ++_i1278) { @@ -18234,7 +18234,7 @@ const ConcourseService_getKeysRecordTimestr_result = class { key1279 = input.readString(); val1280 = new data_ttypes.TObject(); val1280.read(input); - this.success[key1279] = val1280; + this.success.set(key1279, val1280); } input.readMapEnd(); } else { @@ -18400,14 +18400,14 @@ const ConcourseService_getKeysRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31294 = input.readMapBegin(); const _size1293 = _rtmp31294.size || 0; for (let _i1295 = 0; _i1295 < _size1293; ++_i1295) { let key1296 = null; let val1297 = null; key1296 = input.readI64(); - val1297 = {}; + val1297 = new Map(); const _rtmp31299 = input.readMapBegin(); const _size1298 = _rtmp31299.size || 0; for (let _i1300 = 0; _i1300 < _size1298; ++_i1300) { @@ -18416,10 +18416,10 @@ const ConcourseService_getKeysRecords_result = class { key1301 = input.readString(); val1302 = new data_ttypes.TObject(); val1302.read(input); - val1297[key1301] = val1302; + val1297.set(key1301, val1302); } input.readMapEnd(); - this.success[key1296] = val1297; + this.success.set(key1296, val1297); } input.readMapEnd(); } else { @@ -18570,7 +18570,7 @@ const ConcourseService_getKeyRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31313 = input.readMapBegin(); const _size1312 = _rtmp31313.size || 0; for (let _i1314 = 0; _i1314 < _size1312; ++_i1314) { @@ -18579,7 +18579,7 @@ const ConcourseService_getKeyRecords_result = class { key1315 = input.readI64(); val1316 = new data_ttypes.TObject(); val1316.read(input); - this.success[key1315] = val1316; + this.success.set(key1315, val1316); } input.readMapEnd(); } else { @@ -18739,7 +18739,7 @@ const ConcourseService_getKeyRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31325 = input.readMapBegin(); const _size1324 = _rtmp31325.size || 0; for (let _i1326 = 0; _i1326 < _size1324; ++_i1326) { @@ -18748,7 +18748,7 @@ const ConcourseService_getKeyRecordsTime_result = class { key1327 = input.readI64(); val1328 = new data_ttypes.TObject(); val1328.read(input); - this.success[key1327] = val1328; + this.success.set(key1327, val1328); } input.readMapEnd(); } else { @@ -18916,7 +18916,7 @@ const ConcourseService_getKeyRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31337 = input.readMapBegin(); const _size1336 = _rtmp31337.size || 0; for (let _i1338 = 0; _i1338 < _size1336; ++_i1338) { @@ -18925,7 +18925,7 @@ const ConcourseService_getKeyRecordsTimestr_result = class { key1339 = input.readI64(); val1340 = new data_ttypes.TObject(); val1340.read(input); - this.success[key1339] = val1340; + this.success.set(key1339, val1340); } input.readMapEnd(); } else { @@ -19100,14 +19100,14 @@ const ConcourseService_getKeysRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31354 = input.readMapBegin(); const _size1353 = _rtmp31354.size || 0; for (let _i1355 = 0; _i1355 < _size1353; ++_i1355) { let key1356 = null; let val1357 = null; key1356 = input.readI64(); - val1357 = {}; + val1357 = new Map(); const _rtmp31359 = input.readMapBegin(); const _size1358 = _rtmp31359.size || 0; for (let _i1360 = 0; _i1360 < _size1358; ++_i1360) { @@ -19116,10 +19116,10 @@ const ConcourseService_getKeysRecordsTime_result = class { key1361 = input.readString(); val1362 = new data_ttypes.TObject(); val1362.read(input); - val1357[key1361] = val1362; + val1357.set(key1361, val1362); } input.readMapEnd(); - this.success[key1356] = val1357; + this.success.set(key1356, val1357); } input.readMapEnd(); } else { @@ -19294,14 +19294,14 @@ const ConcourseService_getKeysRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31378 = input.readMapBegin(); const _size1377 = _rtmp31378.size || 0; for (let _i1379 = 0; _i1379 < _size1377; ++_i1379) { let key1380 = null; let val1381 = null; key1380 = input.readI64(); - val1381 = {}; + val1381 = new Map(); const _rtmp31383 = input.readMapBegin(); const _size1382 = _rtmp31383.size || 0; for (let _i1384 = 0; _i1384 < _size1382; ++_i1384) { @@ -19310,10 +19310,10 @@ const ConcourseService_getKeysRecordsTimestr_result = class { key1385 = input.readString(); val1386 = new data_ttypes.TObject(); val1386.read(input); - val1381[key1385] = val1386; + val1381.set(key1385, val1386); } input.readMapEnd(); - this.success[key1380] = val1381; + this.success.set(key1380, val1381); } input.readMapEnd(); } else { @@ -19465,7 +19465,7 @@ const ConcourseService_getKeyCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31392 = input.readMapBegin(); const _size1391 = _rtmp31392.size || 0; for (let _i1393 = 0; _i1393 < _size1391; ++_i1393) { @@ -19474,7 +19474,7 @@ const ConcourseService_getKeyCriteria_result = class { key1394 = input.readI64(); val1395 = new data_ttypes.TObject(); val1395.read(input); - this.success[key1394] = val1395; + this.success.set(key1394, val1395); } input.readMapEnd(); } else { @@ -19609,14 +19609,14 @@ const ConcourseService_getCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31399 = input.readMapBegin(); const _size1398 = _rtmp31399.size || 0; for (let _i1400 = 0; _i1400 < _size1398; ++_i1400) { let key1401 = null; let val1402 = null; key1401 = input.readI64(); - val1402 = {}; + val1402 = new Map(); const _rtmp31404 = input.readMapBegin(); const _size1403 = _rtmp31404.size || 0; for (let _i1405 = 0; _i1405 < _size1403; ++_i1405) { @@ -19625,10 +19625,10 @@ const ConcourseService_getCriteria_result = class { key1406 = input.readString(); val1407 = new data_ttypes.TObject(); val1407.read(input); - val1402[key1406] = val1407; + val1402.set(key1406, val1407); } input.readMapEnd(); - this.success[key1401] = val1402; + this.success.set(key1401, val1402); } input.readMapEnd(); } else { @@ -19771,14 +19771,14 @@ const ConcourseService_getCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31413 = input.readMapBegin(); const _size1412 = _rtmp31413.size || 0; for (let _i1414 = 0; _i1414 < _size1412; ++_i1414) { let key1415 = null; let val1416 = null; key1415 = input.readI64(); - val1416 = {}; + val1416 = new Map(); const _rtmp31418 = input.readMapBegin(); const _size1417 = _rtmp31418.size || 0; for (let _i1419 = 0; _i1419 < _size1417; ++_i1419) { @@ -19787,10 +19787,10 @@ const ConcourseService_getCcl_result = class { key1420 = input.readString(); val1421 = new data_ttypes.TObject(); val1421.read(input); - val1416[key1420] = val1421; + val1416.set(key1420, val1421); } input.readMapEnd(); - this.success[key1415] = val1416; + this.success.set(key1415, val1416); } input.readMapEnd(); } else { @@ -19942,14 +19942,14 @@ const ConcourseService_getCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31427 = input.readMapBegin(); const _size1426 = _rtmp31427.size || 0; for (let _i1428 = 0; _i1428 < _size1426; ++_i1428) { let key1429 = null; let val1430 = null; key1429 = input.readI64(); - val1430 = {}; + val1430 = new Map(); const _rtmp31432 = input.readMapBegin(); const _size1431 = _rtmp31432.size || 0; for (let _i1433 = 0; _i1433 < _size1431; ++_i1433) { @@ -19958,10 +19958,10 @@ const ConcourseService_getCriteriaTime_result = class { key1434 = input.readString(); val1435 = new data_ttypes.TObject(); val1435.read(input); - val1430[key1434] = val1435; + val1430.set(key1434, val1435); } input.readMapEnd(); - this.success[key1429] = val1430; + this.success.set(key1429, val1430); } input.readMapEnd(); } else { @@ -20113,14 +20113,14 @@ const ConcourseService_getCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31441 = input.readMapBegin(); const _size1440 = _rtmp31441.size || 0; for (let _i1442 = 0; _i1442 < _size1440; ++_i1442) { let key1443 = null; let val1444 = null; key1443 = input.readI64(); - val1444 = {}; + val1444 = new Map(); const _rtmp31446 = input.readMapBegin(); const _size1445 = _rtmp31446.size || 0; for (let _i1447 = 0; _i1447 < _size1445; ++_i1447) { @@ -20129,10 +20129,10 @@ const ConcourseService_getCriteriaTimestr_result = class { key1448 = input.readString(); val1449 = new data_ttypes.TObject(); val1449.read(input); - val1444[key1448] = val1449; + val1444.set(key1448, val1449); } input.readMapEnd(); - this.success[key1443] = val1444; + this.success.set(key1443, val1444); } input.readMapEnd(); } else { @@ -20292,14 +20292,14 @@ const ConcourseService_getCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31455 = input.readMapBegin(); const _size1454 = _rtmp31455.size || 0; for (let _i1456 = 0; _i1456 < _size1454; ++_i1456) { let key1457 = null; let val1458 = null; key1457 = input.readI64(); - val1458 = {}; + val1458 = new Map(); const _rtmp31460 = input.readMapBegin(); const _size1459 = _rtmp31460.size || 0; for (let _i1461 = 0; _i1461 < _size1459; ++_i1461) { @@ -20308,10 +20308,10 @@ const ConcourseService_getCclTime_result = class { key1462 = input.readString(); val1463 = new data_ttypes.TObject(); val1463.read(input); - val1458[key1462] = val1463; + val1458.set(key1462, val1463); } input.readMapEnd(); - this.success[key1457] = val1458; + this.success.set(key1457, val1458); } input.readMapEnd(); } else { @@ -20471,14 +20471,14 @@ const ConcourseService_getCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31469 = input.readMapBegin(); const _size1468 = _rtmp31469.size || 0; for (let _i1470 = 0; _i1470 < _size1468; ++_i1470) { let key1471 = null; let val1472 = null; key1471 = input.readI64(); - val1472 = {}; + val1472 = new Map(); const _rtmp31474 = input.readMapBegin(); const _size1473 = _rtmp31474.size || 0; for (let _i1475 = 0; _i1475 < _size1473; ++_i1475) { @@ -20487,10 +20487,10 @@ const ConcourseService_getCclTimestr_result = class { key1476 = input.readString(); val1477 = new data_ttypes.TObject(); val1477.read(input); - val1472[key1476] = val1477; + val1472.set(key1476, val1477); } input.readMapEnd(); - this.success[key1471] = val1472; + this.success.set(key1471, val1472); } input.readMapEnd(); } else { @@ -20650,7 +20650,7 @@ const ConcourseService_getKeyCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31483 = input.readMapBegin(); const _size1482 = _rtmp31483.size || 0; for (let _i1484 = 0; _i1484 < _size1482; ++_i1484) { @@ -20659,7 +20659,7 @@ const ConcourseService_getKeyCcl_result = class { key1485 = input.readI64(); val1486 = new data_ttypes.TObject(); val1486.read(input); - this.success[key1485] = val1486; + this.success.set(key1485, val1486); } input.readMapEnd(); } else { @@ -20820,7 +20820,7 @@ const ConcourseService_getKeyCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31490 = input.readMapBegin(); const _size1489 = _rtmp31490.size || 0; for (let _i1491 = 0; _i1491 < _size1489; ++_i1491) { @@ -20829,7 +20829,7 @@ const ConcourseService_getKeyCriteriaTime_result = class { key1492 = input.readI64(); val1493 = new data_ttypes.TObject(); val1493.read(input); - this.success[key1492] = val1493; + this.success.set(key1492, val1493); } input.readMapEnd(); } else { @@ -20990,7 +20990,7 @@ const ConcourseService_getKeyCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31497 = input.readMapBegin(); const _size1496 = _rtmp31497.size || 0; for (let _i1498 = 0; _i1498 < _size1496; ++_i1498) { @@ -20999,7 +20999,7 @@ const ConcourseService_getKeyCriteriaTimestr_result = class { key1499 = input.readI64(); val1500 = new data_ttypes.TObject(); val1500.read(input); - this.success[key1499] = val1500; + this.success.set(key1499, val1500); } input.readMapEnd(); } else { @@ -21168,7 +21168,7 @@ const ConcourseService_getKeyCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31504 = input.readMapBegin(); const _size1503 = _rtmp31504.size || 0; for (let _i1505 = 0; _i1505 < _size1503; ++_i1505) { @@ -21177,7 +21177,7 @@ const ConcourseService_getKeyCclTime_result = class { key1506 = input.readI64(); val1507 = new data_ttypes.TObject(); val1507.read(input); - this.success[key1506] = val1507; + this.success.set(key1506, val1507); } input.readMapEnd(); } else { @@ -21346,7 +21346,7 @@ const ConcourseService_getKeyCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31511 = input.readMapBegin(); const _size1510 = _rtmp31511.size || 0; for (let _i1512 = 0; _i1512 < _size1510; ++_i1512) { @@ -21355,7 +21355,7 @@ const ConcourseService_getKeyCclTimestr_result = class { key1513 = input.readI64(); val1514 = new data_ttypes.TObject(); val1514.read(input); - this.success[key1513] = val1514; + this.success.set(key1513, val1514); } input.readMapEnd(); } else { @@ -21514,14 +21514,14 @@ const ConcourseService_getKeysCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31523 = input.readMapBegin(); const _size1522 = _rtmp31523.size || 0; for (let _i1524 = 0; _i1524 < _size1522; ++_i1524) { let key1525 = null; let val1526 = null; key1525 = input.readI64(); - val1526 = {}; + val1526 = new Map(); const _rtmp31528 = input.readMapBegin(); const _size1527 = _rtmp31528.size || 0; for (let _i1529 = 0; _i1529 < _size1527; ++_i1529) { @@ -21530,10 +21530,10 @@ const ConcourseService_getKeysCriteria_result = class { key1530 = input.readString(); val1531 = new data_ttypes.TObject(); val1531.read(input); - val1526[key1530] = val1531; + val1526.set(key1530, val1531); } input.readMapEnd(); - this.success[key1525] = val1526; + this.success.set(key1525, val1526); } input.readMapEnd(); } else { @@ -21692,14 +21692,14 @@ const ConcourseService_getKeysCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31542 = input.readMapBegin(); const _size1541 = _rtmp31542.size || 0; for (let _i1543 = 0; _i1543 < _size1541; ++_i1543) { let key1544 = null; let val1545 = null; key1544 = input.readI64(); - val1545 = {}; + val1545 = new Map(); const _rtmp31547 = input.readMapBegin(); const _size1546 = _rtmp31547.size || 0; for (let _i1548 = 0; _i1548 < _size1546; ++_i1548) { @@ -21708,10 +21708,10 @@ const ConcourseService_getKeysCcl_result = class { key1549 = input.readString(); val1550 = new data_ttypes.TObject(); val1550.read(input); - val1545[key1549] = val1550; + val1545.set(key1549, val1550); } input.readMapEnd(); - this.success[key1544] = val1545; + this.success.set(key1544, val1545); } input.readMapEnd(); } else { @@ -21879,14 +21879,14 @@ const ConcourseService_getKeysCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31561 = input.readMapBegin(); const _size1560 = _rtmp31561.size || 0; for (let _i1562 = 0; _i1562 < _size1560; ++_i1562) { let key1563 = null; let val1564 = null; key1563 = input.readI64(); - val1564 = {}; + val1564 = new Map(); const _rtmp31566 = input.readMapBegin(); const _size1565 = _rtmp31566.size || 0; for (let _i1567 = 0; _i1567 < _size1565; ++_i1567) { @@ -21895,10 +21895,10 @@ const ConcourseService_getKeysCriteriaTime_result = class { key1568 = input.readString(); val1569 = new data_ttypes.TObject(); val1569.read(input); - val1564[key1568] = val1569; + val1564.set(key1568, val1569); } input.readMapEnd(); - this.success[key1563] = val1564; + this.success.set(key1563, val1564); } input.readMapEnd(); } else { @@ -22066,14 +22066,14 @@ const ConcourseService_getKeysCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31580 = input.readMapBegin(); const _size1579 = _rtmp31580.size || 0; for (let _i1581 = 0; _i1581 < _size1579; ++_i1581) { let key1582 = null; let val1583 = null; key1582 = input.readI64(); - val1583 = {}; + val1583 = new Map(); const _rtmp31585 = input.readMapBegin(); const _size1584 = _rtmp31585.size || 0; for (let _i1586 = 0; _i1586 < _size1584; ++_i1586) { @@ -22082,10 +22082,10 @@ const ConcourseService_getKeysCriteriaTimestr_result = class { key1587 = input.readString(); val1588 = new data_ttypes.TObject(); val1588.read(input); - val1583[key1587] = val1588; + val1583.set(key1587, val1588); } input.readMapEnd(); - this.success[key1582] = val1583; + this.success.set(key1582, val1583); } input.readMapEnd(); } else { @@ -22261,14 +22261,14 @@ const ConcourseService_getKeysCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31599 = input.readMapBegin(); const _size1598 = _rtmp31599.size || 0; for (let _i1600 = 0; _i1600 < _size1598; ++_i1600) { let key1601 = null; let val1602 = null; key1601 = input.readI64(); - val1602 = {}; + val1602 = new Map(); const _rtmp31604 = input.readMapBegin(); const _size1603 = _rtmp31604.size || 0; for (let _i1605 = 0; _i1605 < _size1603; ++_i1605) { @@ -22277,10 +22277,10 @@ const ConcourseService_getKeysCclTime_result = class { key1606 = input.readString(); val1607 = new data_ttypes.TObject(); val1607.read(input); - val1602[key1606] = val1607; + val1602.set(key1606, val1607); } input.readMapEnd(); - this.success[key1601] = val1602; + this.success.set(key1601, val1602); } input.readMapEnd(); } else { @@ -22456,14 +22456,14 @@ const ConcourseService_getKeysCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31618 = input.readMapBegin(); const _size1617 = _rtmp31618.size || 0; for (let _i1619 = 0; _i1619 < _size1617; ++_i1619) { let key1620 = null; let val1621 = null; key1620 = input.readI64(); - val1621 = {}; + val1621 = new Map(); const _rtmp31623 = input.readMapBegin(); const _size1622 = _rtmp31623.size || 0; for (let _i1624 = 0; _i1624 < _size1622; ++_i1624) { @@ -22472,10 +22472,10 @@ const ConcourseService_getKeysCclTimestr_result = class { key1625 = input.readString(); val1626 = new data_ttypes.TObject(); val1626.read(input); - val1621[key1625] = val1626; + val1621.set(key1625, val1626); } input.readMapEnd(); - this.success[key1620] = val1621; + this.success.set(key1620, val1621); } input.readMapEnd(); } else { @@ -26377,7 +26377,7 @@ const ConcourseService_pingRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31767 = input.readMapBegin(); const _size1766 = _rtmp31767.size || 0; for (let _i1768 = 0; _i1768 < _size1766; ++_i1768) { @@ -26385,7 +26385,7 @@ const ConcourseService_pingRecords_result = class { let val1770 = null; key1769 = input.readI64(); val1770 = input.readBool(); - this.success[key1769] = val1770; + this.success.set(key1769, val1770); } input.readMapEnd(); } else { @@ -39190,7 +39190,7 @@ const ConcourseService_navigateKeyRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31849 = input.readMapBegin(); const _size1848 = _rtmp31849.size || 0; for (let _i1850 = 0; _i1850 < _size1848; ++_i1850) { @@ -39207,7 +39207,7 @@ const ConcourseService_navigateKeyRecord_result = class { val1852.push(elem1856); } input.readSetEnd(); - this.success[key1851] = val1852; + this.success.set(key1851, val1852); } input.readMapEnd(); } else { @@ -39360,7 +39360,7 @@ const ConcourseService_navigateKeyRecordTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31861 = input.readMapBegin(); const _size1860 = _rtmp31861.size || 0; for (let _i1862 = 0; _i1862 < _size1860; ++_i1862) { @@ -39377,7 +39377,7 @@ const ConcourseService_navigateKeyRecordTime_result = class { val1864.push(elem1868); } input.readSetEnd(); - this.success[key1863] = val1864; + this.success.set(key1863, val1864); } input.readMapEnd(); } else { @@ -39538,7 +39538,7 @@ const ConcourseService_navigateKeyRecordTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31873 = input.readMapBegin(); const _size1872 = _rtmp31873.size || 0; for (let _i1874 = 0; _i1874 < _size1872; ++_i1874) { @@ -39555,7 +39555,7 @@ const ConcourseService_navigateKeyRecordTimestr_result = class { val1876.push(elem1880); } input.readSetEnd(); - this.success[key1875] = val1876; + this.success.set(key1875, val1876); } input.readMapEnd(); } else { @@ -39714,14 +39714,14 @@ const ConcourseService_navigateKeysRecord_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31890 = input.readMapBegin(); const _size1889 = _rtmp31890.size || 0; for (let _i1891 = 0; _i1891 < _size1889; ++_i1891) { let key1892 = null; let val1893 = null; key1892 = input.readI64(); - val1893 = {}; + val1893 = new Map(); const _rtmp31895 = input.readMapBegin(); const _size1894 = _rtmp31895.size || 0; for (let _i1896 = 0; _i1896 < _size1894; ++_i1896) { @@ -39738,10 +39738,10 @@ const ConcourseService_navigateKeysRecord_result = class { val1898.push(elem1902); } input.readSetEnd(); - val1893[key1897] = val1898; + val1893.set(key1897, val1898); } input.readMapEnd(); - this.success[key1892] = val1893; + this.success.set(key1892, val1893); } input.readMapEnd(); } else { @@ -39901,14 +39901,14 @@ const ConcourseService_navigateKeysRecordTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31914 = input.readMapBegin(); const _size1913 = _rtmp31914.size || 0; for (let _i1915 = 0; _i1915 < _size1913; ++_i1915) { let key1916 = null; let val1917 = null; key1916 = input.readI64(); - val1917 = {}; + val1917 = new Map(); const _rtmp31919 = input.readMapBegin(); const _size1918 = _rtmp31919.size || 0; for (let _i1920 = 0; _i1920 < _size1918; ++_i1920) { @@ -39925,10 +39925,10 @@ const ConcourseService_navigateKeysRecordTime_result = class { val1922.push(elem1926); } input.readSetEnd(); - val1917[key1921] = val1922; + val1917.set(key1921, val1922); } input.readMapEnd(); - this.success[key1916] = val1917; + this.success.set(key1916, val1917); } input.readMapEnd(); } else { @@ -40096,14 +40096,14 @@ const ConcourseService_navigateKeysRecordTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31938 = input.readMapBegin(); const _size1937 = _rtmp31938.size || 0; for (let _i1939 = 0; _i1939 < _size1937; ++_i1939) { let key1940 = null; let val1941 = null; key1940 = input.readI64(); - val1941 = {}; + val1941 = new Map(); const _rtmp31943 = input.readMapBegin(); const _size1942 = _rtmp31943.size || 0; for (let _i1944 = 0; _i1944 < _size1942; ++_i1944) { @@ -40120,10 +40120,10 @@ const ConcourseService_navigateKeysRecordTimestr_result = class { val1946.push(elem1950); } input.readSetEnd(); - val1941[key1945] = val1946; + val1941.set(key1945, val1946); } input.readMapEnd(); - this.success[key1940] = val1941; + this.success.set(key1940, val1941); } input.readMapEnd(); } else { @@ -40289,14 +40289,14 @@ const ConcourseService_navigateKeysRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31967 = input.readMapBegin(); const _size1966 = _rtmp31967.size || 0; for (let _i1968 = 0; _i1968 < _size1966; ++_i1968) { let key1969 = null; let val1970 = null; key1969 = input.readI64(); - val1970 = {}; + val1970 = new Map(); const _rtmp31972 = input.readMapBegin(); const _size1971 = _rtmp31972.size || 0; for (let _i1973 = 0; _i1973 < _size1971; ++_i1973) { @@ -40313,10 +40313,10 @@ const ConcourseService_navigateKeysRecords_result = class { val1975.push(elem1979); } input.readSetEnd(); - val1970[key1974] = val1975; + val1970.set(key1974, val1975); } input.readMapEnd(); - this.success[key1969] = val1970; + this.success.set(key1969, val1970); } input.readMapEnd(); } else { @@ -40467,7 +40467,7 @@ const ConcourseService_navigateKeyRecords_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp31991 = input.readMapBegin(); const _size1990 = _rtmp31991.size || 0; for (let _i1992 = 0; _i1992 < _size1990; ++_i1992) { @@ -40484,7 +40484,7 @@ const ConcourseService_navigateKeyRecords_result = class { val1994.push(elem1998); } input.readSetEnd(); - this.success[key1993] = val1994; + this.success.set(key1993, val1994); } input.readMapEnd(); } else { @@ -40644,7 +40644,7 @@ const ConcourseService_navigateKeyRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32008 = input.readMapBegin(); const _size2007 = _rtmp32008.size || 0; for (let _i2009 = 0; _i2009 < _size2007; ++_i2009) { @@ -40661,7 +40661,7 @@ const ConcourseService_navigateKeyRecordsTime_result = class { val2011.push(elem2015); } input.readSetEnd(); - this.success[key2010] = val2011; + this.success.set(key2010, val2011); } input.readMapEnd(); } else { @@ -40829,7 +40829,7 @@ const ConcourseService_navigateKeyRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32025 = input.readMapBegin(); const _size2024 = _rtmp32025.size || 0; for (let _i2026 = 0; _i2026 < _size2024; ++_i2026) { @@ -40846,7 +40846,7 @@ const ConcourseService_navigateKeyRecordsTimestr_result = class { val2028.push(elem2032); } input.readSetEnd(); - this.success[key2027] = val2028; + this.success.set(key2027, val2028); } input.readMapEnd(); } else { @@ -41021,14 +41021,14 @@ const ConcourseService_navigateKeysRecordsTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32047 = input.readMapBegin(); const _size2046 = _rtmp32047.size || 0; for (let _i2048 = 0; _i2048 < _size2046; ++_i2048) { let key2049 = null; let val2050 = null; key2049 = input.readI64(); - val2050 = {}; + val2050 = new Map(); const _rtmp32052 = input.readMapBegin(); const _size2051 = _rtmp32052.size || 0; for (let _i2053 = 0; _i2053 < _size2051; ++_i2053) { @@ -41045,10 +41045,10 @@ const ConcourseService_navigateKeysRecordsTime_result = class { val2055.push(elem2059); } input.readSetEnd(); - val2050[key2054] = val2055; + val2050.set(key2054, val2055); } input.readMapEnd(); - this.success[key2049] = val2050; + this.success.set(key2049, val2050); } input.readMapEnd(); } else { @@ -41223,14 +41223,14 @@ const ConcourseService_navigateKeysRecordsTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32076 = input.readMapBegin(); const _size2075 = _rtmp32076.size || 0; for (let _i2077 = 0; _i2077 < _size2075; ++_i2077) { let key2078 = null; let val2079 = null; key2078 = input.readI64(); - val2079 = {}; + val2079 = new Map(); const _rtmp32081 = input.readMapBegin(); const _size2080 = _rtmp32081.size || 0; for (let _i2082 = 0; _i2082 < _size2080; ++_i2082) { @@ -41247,10 +41247,10 @@ const ConcourseService_navigateKeysRecordsTimestr_result = class { val2084.push(elem2088); } input.readSetEnd(); - val2079[key2083] = val2084; + val2079.set(key2083, val2084); } input.readMapEnd(); - this.success[key2078] = val2079; + this.success.set(key2078, val2079); } input.readMapEnd(); } else { @@ -41410,7 +41410,7 @@ const ConcourseService_navigateKeyCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32095 = input.readMapBegin(); const _size2094 = _rtmp32095.size || 0; for (let _i2096 = 0; _i2096 < _size2094; ++_i2096) { @@ -41427,7 +41427,7 @@ const ConcourseService_navigateKeyCcl_result = class { val2098.push(elem2102); } input.readSetEnd(); - this.success[key2097] = val2098; + this.success.set(key2097, val2098); } input.readMapEnd(); } else { @@ -41596,7 +41596,7 @@ const ConcourseService_navigateKeyCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32107 = input.readMapBegin(); const _size2106 = _rtmp32107.size || 0; for (let _i2108 = 0; _i2108 < _size2106; ++_i2108) { @@ -41613,7 +41613,7 @@ const ConcourseService_navigateKeyCclTime_result = class { val2110.push(elem2114); } input.readSetEnd(); - this.success[key2109] = val2110; + this.success.set(key2109, val2110); } input.readMapEnd(); } else { @@ -41782,7 +41782,7 @@ const ConcourseService_navigateKeyCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32119 = input.readMapBegin(); const _size2118 = _rtmp32119.size || 0; for (let _i2120 = 0; _i2120 < _size2118; ++_i2120) { @@ -41799,7 +41799,7 @@ const ConcourseService_navigateKeyCclTimestr_result = class { val2122.push(elem2126); } input.readSetEnd(); - this.success[key2121] = val2122; + this.success.set(key2121, val2122); } input.readMapEnd(); } else { @@ -41966,14 +41966,14 @@ const ConcourseService_navigateKeysCcl_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32136 = input.readMapBegin(); const _size2135 = _rtmp32136.size || 0; for (let _i2137 = 0; _i2137 < _size2135; ++_i2137) { let key2138 = null; let val2139 = null; key2138 = input.readI64(); - val2139 = {}; + val2139 = new Map(); const _rtmp32141 = input.readMapBegin(); const _size2140 = _rtmp32141.size || 0; for (let _i2142 = 0; _i2142 < _size2140; ++_i2142) { @@ -41990,10 +41990,10 @@ const ConcourseService_navigateKeysCcl_result = class { val2144.push(elem2148); } input.readSetEnd(); - val2139[key2143] = val2144; + val2139.set(key2143, val2144); } input.readMapEnd(); - this.success[key2138] = val2139; + this.success.set(key2138, val2139); } input.readMapEnd(); } else { @@ -42169,14 +42169,14 @@ const ConcourseService_navigateKeysCclTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32160 = input.readMapBegin(); const _size2159 = _rtmp32160.size || 0; for (let _i2161 = 0; _i2161 < _size2159; ++_i2161) { let key2162 = null; let val2163 = null; key2162 = input.readI64(); - val2163 = {}; + val2163 = new Map(); const _rtmp32165 = input.readMapBegin(); const _size2164 = _rtmp32165.size || 0; for (let _i2166 = 0; _i2166 < _size2164; ++_i2166) { @@ -42193,10 +42193,10 @@ const ConcourseService_navigateKeysCclTime_result = class { val2168.push(elem2172); } input.readSetEnd(); - val2163[key2167] = val2168; + val2163.set(key2167, val2168); } input.readMapEnd(); - this.success[key2162] = val2163; + this.success.set(key2162, val2163); } input.readMapEnd(); } else { @@ -42372,14 +42372,14 @@ const ConcourseService_navigateKeysCclTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32184 = input.readMapBegin(); const _size2183 = _rtmp32184.size || 0; for (let _i2185 = 0; _i2185 < _size2183; ++_i2185) { let key2186 = null; let val2187 = null; key2186 = input.readI64(); - val2187 = {}; + val2187 = new Map(); const _rtmp32189 = input.readMapBegin(); const _size2188 = _rtmp32189.size || 0; for (let _i2190 = 0; _i2190 < _size2188; ++_i2190) { @@ -42396,10 +42396,10 @@ const ConcourseService_navigateKeysCclTimestr_result = class { val2192.push(elem2196); } input.readSetEnd(); - val2187[key2191] = val2192; + val2187.set(key2191, val2192); } input.readMapEnd(); - this.success[key2186] = val2187; + this.success.set(key2186, val2187); } input.readMapEnd(); } else { @@ -42559,7 +42559,7 @@ const ConcourseService_navigateKeyCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32203 = input.readMapBegin(); const _size2202 = _rtmp32203.size || 0; for (let _i2204 = 0; _i2204 < _size2202; ++_i2204) { @@ -42576,7 +42576,7 @@ const ConcourseService_navigateKeyCriteria_result = class { val2206.push(elem2210); } input.readSetEnd(); - this.success[key2205] = val2206; + this.success.set(key2205, val2206); } input.readMapEnd(); } else { @@ -42745,7 +42745,7 @@ const ConcourseService_navigateKeyCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32215 = input.readMapBegin(); const _size2214 = _rtmp32215.size || 0; for (let _i2216 = 0; _i2216 < _size2214; ++_i2216) { @@ -42762,7 +42762,7 @@ const ConcourseService_navigateKeyCriteriaTime_result = class { val2218.push(elem2222); } input.readSetEnd(); - this.success[key2217] = val2218; + this.success.set(key2217, val2218); } input.readMapEnd(); } else { @@ -42931,7 +42931,7 @@ const ConcourseService_navigateKeyCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32227 = input.readMapBegin(); const _size2226 = _rtmp32227.size || 0; for (let _i2228 = 0; _i2228 < _size2226; ++_i2228) { @@ -42948,7 +42948,7 @@ const ConcourseService_navigateKeyCriteriaTimestr_result = class { val2230.push(elem2234); } input.readSetEnd(); - this.success[key2229] = val2230; + this.success.set(key2229, val2230); } input.readMapEnd(); } else { @@ -43115,14 +43115,14 @@ const ConcourseService_navigateKeysCriteria_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32244 = input.readMapBegin(); const _size2243 = _rtmp32244.size || 0; for (let _i2245 = 0; _i2245 < _size2243; ++_i2245) { let key2246 = null; let val2247 = null; key2246 = input.readI64(); - val2247 = {}; + val2247 = new Map(); const _rtmp32249 = input.readMapBegin(); const _size2248 = _rtmp32249.size || 0; for (let _i2250 = 0; _i2250 < _size2248; ++_i2250) { @@ -43139,10 +43139,10 @@ const ConcourseService_navigateKeysCriteria_result = class { val2252.push(elem2256); } input.readSetEnd(); - val2247[key2251] = val2252; + val2247.set(key2251, val2252); } input.readMapEnd(); - this.success[key2246] = val2247; + this.success.set(key2246, val2247); } input.readMapEnd(); } else { @@ -43318,14 +43318,14 @@ const ConcourseService_navigateKeysCriteriaTime_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32268 = input.readMapBegin(); const _size2267 = _rtmp32268.size || 0; for (let _i2269 = 0; _i2269 < _size2267; ++_i2269) { let key2270 = null; let val2271 = null; key2270 = input.readI64(); - val2271 = {}; + val2271 = new Map(); const _rtmp32273 = input.readMapBegin(); const _size2272 = _rtmp32273.size || 0; for (let _i2274 = 0; _i2274 < _size2272; ++_i2274) { @@ -43342,10 +43342,10 @@ const ConcourseService_navigateKeysCriteriaTime_result = class { val2276.push(elem2280); } input.readSetEnd(); - val2271[key2275] = val2276; + val2271.set(key2275, val2276); } input.readMapEnd(); - this.success[key2270] = val2271; + this.success.set(key2270, val2271); } input.readMapEnd(); } else { @@ -43521,14 +43521,14 @@ const ConcourseService_navigateKeysCriteriaTimestr_result = class { switch (fid) { case 0: if (ftype == Thrift.Type.MAP) { - this.success = {}; + this.success = new Map(); const _rtmp32292 = input.readMapBegin(); const _size2291 = _rtmp32292.size || 0; for (let _i2293 = 0; _i2293 < _size2291; ++_i2293) { let key2294 = null; let val2295 = null; key2294 = input.readI64(); - val2295 = {}; + val2295 = new Map(); const _rtmp32297 = input.readMapBegin(); const _size2296 = _rtmp32297.size || 0; for (let _i2298 = 0; _i2298 < _size2296; ++_i2298) { @@ -43545,10 +43545,10 @@ const ConcourseService_navigateKeysCriteriaTimestr_result = class { val2300.push(elem2304); } input.readSetEnd(); - val2295[key2299] = val2300; + val2295.set(key2299, val2300); } input.readMapEnd(); - this.success[key2294] = val2295; + this.success.set(key2294, val2295); } input.readMapEnd(); } else { diff --git a/concourse-driver-node-js/src/thrift/ConcourseService.js.bak b/concourse-driver-node-js/src/thrift/ConcourseService.js.bak deleted file mode 100644 index 28c9c36145..0000000000 --- a/concourse-driver-node-js/src/thrift/ConcourseService.js.bak +++ /dev/null @@ -1,101112 +0,0 @@ -// -// Autogenerated by Thrift Compiler (0.12.0) -// -// DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING -// -"use strict"; - -const thrift = require('thrift'); -const Thrift = thrift.Thrift; - -const data_ttypes = require('./data_types'); -const shared_ttypes = require('./shared_types'); -const exceptions_ttypes = require('./exceptions_types'); -const complex_ttypes = require('./complex_types'); - - -const ttypes = require('./concourse_types'); -//HELPER FUNCTIONS AND STRUCTURES - -const ConcourseService_abort_args = class { - constructor(args) { - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_abort_args'); - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 3); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_abort_result = class { - constructor(args) { - this.ex = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 0: - input.skip(ftype); - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_abort_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_addKeyValue_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_addKeyValue_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_addKeyValue_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_addKeyValue_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_addKeyValueRecord_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_addKeyValueRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_addKeyValueRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_addKeyValueRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_addKeyValueRecords_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31 = input.readListBegin(); - const _size0 = _rtmp31.size || 0; - for (let _i2 = 0; _i2 < _size0; ++_i2) { - let elem3 = null; - elem3 = input.readI64(); - this.records.push(elem3); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_addKeyValueRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter4 in this.records) { - if (this.records.hasOwnProperty(iter4)) { - iter4 = this.records[iter4]; - output.writeI64(iter4); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_addKeyValueRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp36 = input.readMapBegin(); - const _size5 = _rtmp36.size || 0; - for (let _i7 = 0; _i7 < _size5; ++_i7) { - let key8 = null; - let val9 = null; - key8 = input.readI64(); - val9 = input.readBool(); - this.success[key8] = val9; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_addKeyValueRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); - for (let kiter10 in this.success) { - if (this.success.hasOwnProperty(kiter10)) { - let viter11 = this.success[kiter10]; - output.writeI64(kiter10); - output.writeBool(viter11); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecord_args = class { - constructor(args) { - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecord_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp313 = input.readMapBegin(); - const _size12 = _rtmp313.size || 0; - for (let _i14 = 0; _i14 < _size12; ++_i14) { - let key15 = null; - let val16 = null; - key15 = input.readI64(); - val16 = input.readString(); - this.success[key15] = val16; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter17 in this.success) { - if (this.success.hasOwnProperty(kiter17)) { - let viter18 = this.success[kiter17]; - output.writeI64(kiter17); - output.writeString(viter18); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStart_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStart_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 2); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStart_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp320 = input.readMapBegin(); - const _size19 = _rtmp320.size || 0; - for (let _i21 = 0; _i21 < _size19; ++_i21) { - let key22 = null; - let val23 = null; - key22 = input.readI64(); - val23 = input.readString(); - this.success[key22] = val23; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStart_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter24 in this.success) { - if (this.success.hasOwnProperty(kiter24)) { - let viter25 = this.success[kiter24]; - output.writeI64(kiter24); - output.writeString(viter25); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStartstr_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStartstr_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 2); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStartstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp327 = input.readMapBegin(); - const _size26 = _rtmp327.size || 0; - for (let _i28 = 0; _i28 < _size26; ++_i28) { - let key29 = null; - let val30 = null; - key29 = input.readI64(); - val30 = input.readString(); - this.success[key29] = val30; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStartstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter31 in this.success) { - if (this.success.hasOwnProperty(kiter31)) { - let viter32 = this.success[kiter31]; - output.writeI64(kiter31); - output.writeString(viter32); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStartEnd_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.tend = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStartEnd_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 2); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.I64, 3); - output.writeI64(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStartEnd_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp334 = input.readMapBegin(); - const _size33 = _rtmp334.size || 0; - for (let _i35 = 0; _i35 < _size33; ++_i35) { - let key36 = null; - let val37 = null; - key36 = input.readI64(); - val37 = input.readString(); - this.success[key36] = val37; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStartEnd_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter38 in this.success) { - if (this.success.hasOwnProperty(kiter38)) { - let viter39 = this.success[kiter38]; - output.writeI64(kiter38); - output.writeString(viter39); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStartstrEndstr_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.tend = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStartstrEndstr_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 2); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.STRING, 3); - output.writeString(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditRecordStartstrEndstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp341 = input.readMapBegin(); - const _size40 = _rtmp341.size || 0; - for (let _i42 = 0; _i42 < _size40; ++_i42) { - let key43 = null; - let val44 = null; - key43 = input.readI64(); - val44 = input.readString(); - this.success[key43] = val44; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditRecordStartstrEndstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter45 in this.success) { - if (this.success.hasOwnProperty(kiter45)) { - let viter46 = this.success[kiter45]; - output.writeI64(kiter45); - output.writeString(viter46); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp348 = input.readMapBegin(); - const _size47 = _rtmp348.size || 0; - for (let _i49 = 0; _i49 < _size47; ++_i49) { - let key50 = null; - let val51 = null; - key50 = input.readI64(); - val51 = input.readString(); - this.success[key50] = val51; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter52 in this.success) { - if (this.success.hasOwnProperty(kiter52)) { - let viter53 = this.success[kiter52]; - output.writeI64(kiter52); - output.writeString(viter53); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStart_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStart_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 3); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStart_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp355 = input.readMapBegin(); - const _size54 = _rtmp355.size || 0; - for (let _i56 = 0; _i56 < _size54; ++_i56) { - let key57 = null; - let val58 = null; - key57 = input.readI64(); - val58 = input.readString(); - this.success[key57] = val58; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStart_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter59 in this.success) { - if (this.success.hasOwnProperty(kiter59)) { - let viter60 = this.success[kiter59]; - output.writeI64(kiter59); - output.writeString(viter60); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStartstr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStartstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 3); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStartstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp362 = input.readMapBegin(); - const _size61 = _rtmp362.size || 0; - for (let _i63 = 0; _i63 < _size61; ++_i63) { - let key64 = null; - let val65 = null; - key64 = input.readI64(); - val65 = input.readString(); - this.success[key64] = val65; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStartstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter66 in this.success) { - if (this.success.hasOwnProperty(kiter66)) { - let viter67 = this.success[kiter66]; - output.writeI64(kiter66); - output.writeString(viter67); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStartEnd_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.I64) { - this.tend = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStartEnd_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 3); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.I64, 4); - output.writeI64(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStartEnd_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp369 = input.readMapBegin(); - const _size68 = _rtmp369.size || 0; - for (let _i70 = 0; _i70 < _size68; ++_i70) { - let key71 = null; - let val72 = null; - key71 = input.readI64(); - val72 = input.readString(); - this.success[key71] = val72; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStartEnd_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter73 in this.success) { - if (this.success.hasOwnProperty(kiter73)) { - let viter74 = this.success[kiter73]; - output.writeI64(kiter73); - output.writeString(viter74); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStartstrEndstr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.tend = input.readString(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStartstrEndstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 3); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.STRING, 4); - output.writeString(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_auditKeyRecordStartstrEndstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp376 = input.readMapBegin(); - const _size75 = _rtmp376.size || 0; - for (let _i77 = 0; _i77 < _size75; ++_i77) { - let key78 = null; - let val79 = null; - key78 = input.readI64(); - val79 = input.readString(); - this.success[key78] = val79; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_auditKeyRecordStartstrEndstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRING, Thrift.objectLength(this.success)); - for (let kiter80 in this.success) { - if (this.success.hasOwnProperty(kiter80)) { - let viter81 = this.success[kiter80]; - output.writeI64(kiter80); - output.writeString(viter81); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKey_args = class { - constructor(args) { - this.key = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKey_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKey_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp383 = input.readMapBegin(); - const _size82 = _rtmp383.size || 0; - for (let _i84 = 0; _i84 < _size82; ++_i84) { - let key85 = null; - let val86 = null; - key85 = new data_ttypes.TObject(); - key85.read(input); - val86 = []; - const _rtmp388 = input.readSetBegin(); - const _size87 = _rtmp388.size || 0; - for (let _i89 = 0; _i89 < _size87; ++_i89) { - let elem90 = null; - elem90 = input.readI64(); - val86.push(elem90); - } - input.readSetEnd(); - this.success[key85] = val86; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKey_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter91 in this.success) { - if (this.success.hasOwnProperty(kiter91)) { - let viter92 = this.success[kiter91]; - kiter91.write(output); - output.writeSetBegin(Thrift.Type.I64, viter92.length); - for (let iter93 in viter92) { - if (viter92.hasOwnProperty(iter93)) { - iter93 = viter92[iter93]; - output.writeI64(iter93); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeys_args = class { - constructor(args) { - this.keys = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp395 = input.readListBegin(); - const _size94 = _rtmp395.size || 0; - for (let _i96 = 0; _i96 < _size94; ++_i96) { - let elem97 = null; - elem97 = input.readString(); - this.keys.push(elem97); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeys_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter98 in this.keys) { - if (this.keys.hasOwnProperty(iter98)) { - iter98 = this.keys[iter98]; - output.writeString(iter98); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeys_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3100 = input.readMapBegin(); - const _size99 = _rtmp3100.size || 0; - for (let _i101 = 0; _i101 < _size99; ++_i101) { - let key102 = null; - let val103 = null; - key102 = input.readString(); - val103 = {}; - const _rtmp3105 = input.readMapBegin(); - const _size104 = _rtmp3105.size || 0; - for (let _i106 = 0; _i106 < _size104; ++_i106) { - let key107 = null; - let val108 = null; - key107 = new data_ttypes.TObject(); - key107.read(input); - val108 = []; - const _rtmp3110 = input.readSetBegin(); - const _size109 = _rtmp3110.size || 0; - for (let _i111 = 0; _i111 < _size109; ++_i111) { - let elem112 = null; - elem112 = input.readI64(); - val108.push(elem112); - } - input.readSetEnd(); - val103[key107] = val108; - } - input.readMapEnd(); - this.success[key102] = val103; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeys_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter113 in this.success) { - if (this.success.hasOwnProperty(kiter113)) { - let viter114 = this.success[kiter113]; - output.writeString(kiter113); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(viter114)); - for (let kiter115 in viter114) { - if (viter114.hasOwnProperty(kiter115)) { - let viter116 = viter114[kiter115]; - kiter115.write(output); - output.writeSetBegin(Thrift.Type.I64, viter116.length); - for (let iter117 in viter116) { - if (viter116.hasOwnProperty(iter117)) { - iter117 = viter116[iter117]; - output.writeI64(iter117); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeyTime_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeyTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeyTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3119 = input.readMapBegin(); - const _size118 = _rtmp3119.size || 0; - for (let _i120 = 0; _i120 < _size118; ++_i120) { - let key121 = null; - let val122 = null; - key121 = new data_ttypes.TObject(); - key121.read(input); - val122 = []; - const _rtmp3124 = input.readSetBegin(); - const _size123 = _rtmp3124.size || 0; - for (let _i125 = 0; _i125 < _size123; ++_i125) { - let elem126 = null; - elem126 = input.readI64(); - val122.push(elem126); - } - input.readSetEnd(); - this.success[key121] = val122; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeyTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter127 in this.success) { - if (this.success.hasOwnProperty(kiter127)) { - let viter128 = this.success[kiter127]; - kiter127.write(output); - output.writeSetBegin(Thrift.Type.I64, viter128.length); - for (let iter129 in viter128) { - if (viter128.hasOwnProperty(iter129)) { - iter129 = viter128[iter129]; - output.writeI64(iter129); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeyTimestr_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeyTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeyTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3131 = input.readMapBegin(); - const _size130 = _rtmp3131.size || 0; - for (let _i132 = 0; _i132 < _size130; ++_i132) { - let key133 = null; - let val134 = null; - key133 = new data_ttypes.TObject(); - key133.read(input); - val134 = []; - const _rtmp3136 = input.readSetBegin(); - const _size135 = _rtmp3136.size || 0; - for (let _i137 = 0; _i137 < _size135; ++_i137) { - let elem138 = null; - elem138 = input.readI64(); - val134.push(elem138); - } - input.readSetEnd(); - this.success[key133] = val134; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeyTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter139 in this.success) { - if (this.success.hasOwnProperty(kiter139)) { - let viter140 = this.success[kiter139]; - kiter139.write(output); - output.writeSetBegin(Thrift.Type.I64, viter140.length); - for (let iter141 in viter140) { - if (viter140.hasOwnProperty(iter141)) { - iter141 = viter140[iter141]; - output.writeI64(iter141); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeysTime_args = class { - constructor(args) { - this.keys = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3143 = input.readListBegin(); - const _size142 = _rtmp3143.size || 0; - for (let _i144 = 0; _i144 < _size142; ++_i144) { - let elem145 = null; - elem145 = input.readString(); - this.keys.push(elem145); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeysTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter146 in this.keys) { - if (this.keys.hasOwnProperty(iter146)) { - iter146 = this.keys[iter146]; - output.writeString(iter146); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeysTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3148 = input.readMapBegin(); - const _size147 = _rtmp3148.size || 0; - for (let _i149 = 0; _i149 < _size147; ++_i149) { - let key150 = null; - let val151 = null; - key150 = input.readString(); - val151 = {}; - const _rtmp3153 = input.readMapBegin(); - const _size152 = _rtmp3153.size || 0; - for (let _i154 = 0; _i154 < _size152; ++_i154) { - let key155 = null; - let val156 = null; - key155 = new data_ttypes.TObject(); - key155.read(input); - val156 = []; - const _rtmp3158 = input.readSetBegin(); - const _size157 = _rtmp3158.size || 0; - for (let _i159 = 0; _i159 < _size157; ++_i159) { - let elem160 = null; - elem160 = input.readI64(); - val156.push(elem160); - } - input.readSetEnd(); - val151[key155] = val156; - } - input.readMapEnd(); - this.success[key150] = val151; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeysTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter161 in this.success) { - if (this.success.hasOwnProperty(kiter161)) { - let viter162 = this.success[kiter161]; - output.writeString(kiter161); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(viter162)); - for (let kiter163 in viter162) { - if (viter162.hasOwnProperty(kiter163)) { - let viter164 = viter162[kiter163]; - kiter163.write(output); - output.writeSetBegin(Thrift.Type.I64, viter164.length); - for (let iter165 in viter164) { - if (viter164.hasOwnProperty(iter165)) { - iter165 = viter164[iter165]; - output.writeI64(iter165); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeysTimestr_args = class { - constructor(args) { - this.keys = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3167 = input.readListBegin(); - const _size166 = _rtmp3167.size || 0; - for (let _i168 = 0; _i168 < _size166; ++_i168) { - let elem169 = null; - elem169 = input.readString(); - this.keys.push(elem169); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeysTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter170 in this.keys) { - if (this.keys.hasOwnProperty(iter170)) { - iter170 = this.keys[iter170]; - output.writeString(iter170); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_browseKeysTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3172 = input.readMapBegin(); - const _size171 = _rtmp3172.size || 0; - for (let _i173 = 0; _i173 < _size171; ++_i173) { - let key174 = null; - let val175 = null; - key174 = input.readString(); - val175 = {}; - const _rtmp3177 = input.readMapBegin(); - const _size176 = _rtmp3177.size || 0; - for (let _i178 = 0; _i178 < _size176; ++_i178) { - let key179 = null; - let val180 = null; - key179 = new data_ttypes.TObject(); - key179.read(input); - val180 = []; - const _rtmp3182 = input.readSetBegin(); - const _size181 = _rtmp3182.size || 0; - for (let _i183 = 0; _i183 < _size181; ++_i183) { - let elem184 = null; - elem184 = input.readI64(); - val180.push(elem184); - } - input.readSetEnd(); - val175[key179] = val180; - } - input.readMapEnd(); - this.success[key174] = val175; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_browseKeysTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter185 in this.success) { - if (this.success.hasOwnProperty(kiter185)) { - let viter186 = this.success[kiter185]; - output.writeString(kiter185); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.SET, Thrift.objectLength(viter186)); - for (let kiter187 in viter186) { - if (viter186.hasOwnProperty(kiter187)) { - let viter188 = viter186[kiter187]; - kiter187.write(output); - output.writeSetBegin(Thrift.Type.I64, viter188.length); - for (let iter189 in viter188) { - if (viter188.hasOwnProperty(iter189)) { - iter189 = viter188[iter189]; - output.writeI64(iter189); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3191 = input.readMapBegin(); - const _size190 = _rtmp3191.size || 0; - for (let _i192 = 0; _i192 < _size190; ++_i192) { - let key193 = null; - let val194 = null; - key193 = input.readI64(); - val194 = []; - const _rtmp3196 = input.readSetBegin(); - const _size195 = _rtmp3196.size || 0; - for (let _i197 = 0; _i197 < _size195; ++_i197) { - let elem198 = null; - elem198 = new data_ttypes.TObject(); - elem198.read(input); - val194.push(elem198); - } - input.readSetEnd(); - this.success[key193] = val194; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter199 in this.success) { - if (this.success.hasOwnProperty(kiter199)) { - let viter200 = this.success[kiter199]; - output.writeI64(kiter199); - output.writeSetBegin(Thrift.Type.STRUCT, viter200.length); - for (let iter201 in viter200) { - if (viter200.hasOwnProperty(iter201)) { - iter201 = viter200[iter201]; - iter201.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStart_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStart_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 3); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStart_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3203 = input.readMapBegin(); - const _size202 = _rtmp3203.size || 0; - for (let _i204 = 0; _i204 < _size202; ++_i204) { - let key205 = null; - let val206 = null; - key205 = input.readI64(); - val206 = []; - const _rtmp3208 = input.readSetBegin(); - const _size207 = _rtmp3208.size || 0; - for (let _i209 = 0; _i209 < _size207; ++_i209) { - let elem210 = null; - elem210 = new data_ttypes.TObject(); - elem210.read(input); - val206.push(elem210); - } - input.readSetEnd(); - this.success[key205] = val206; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStart_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter211 in this.success) { - if (this.success.hasOwnProperty(kiter211)) { - let viter212 = this.success[kiter211]; - output.writeI64(kiter211); - output.writeSetBegin(Thrift.Type.STRUCT, viter212.length); - for (let iter213 in viter212) { - if (viter212.hasOwnProperty(iter213)) { - iter213 = viter212[iter213]; - iter213.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStartstr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 3); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStartstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3215 = input.readMapBegin(); - const _size214 = _rtmp3215.size || 0; - for (let _i216 = 0; _i216 < _size214; ++_i216) { - let key217 = null; - let val218 = null; - key217 = input.readI64(); - val218 = []; - const _rtmp3220 = input.readSetBegin(); - const _size219 = _rtmp3220.size || 0; - for (let _i221 = 0; _i221 < _size219; ++_i221) { - let elem222 = null; - elem222 = new data_ttypes.TObject(); - elem222.read(input); - val218.push(elem222); - } - input.readSetEnd(); - this.success[key217] = val218; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter223 in this.success) { - if (this.success.hasOwnProperty(kiter223)) { - let viter224 = this.success[kiter223]; - output.writeI64(kiter223); - output.writeSetBegin(Thrift.Type.STRUCT, viter224.length); - for (let iter225 in viter224) { - if (viter224.hasOwnProperty(iter225)) { - iter225 = viter224[iter225]; - iter225.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStartEnd_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.I64) { - this.tend = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartEnd_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 3); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.I64, 4); - output.writeI64(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStartEnd_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3227 = input.readMapBegin(); - const _size226 = _rtmp3227.size || 0; - for (let _i228 = 0; _i228 < _size226; ++_i228) { - let key229 = null; - let val230 = null; - key229 = input.readI64(); - val230 = []; - const _rtmp3232 = input.readSetBegin(); - const _size231 = _rtmp3232.size || 0; - for (let _i233 = 0; _i233 < _size231; ++_i233) { - let elem234 = null; - elem234 = new data_ttypes.TObject(); - elem234.read(input); - val230.push(elem234); - } - input.readSetEnd(); - this.success[key229] = val230; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartEnd_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter235 in this.success) { - if (this.success.hasOwnProperty(kiter235)) { - let viter236 = this.success[kiter235]; - output.writeI64(kiter235); - output.writeSetBegin(Thrift.Type.STRUCT, viter236.length); - for (let iter237 in viter236) { - if (viter236.hasOwnProperty(iter237)) { - iter237 = viter236[iter237]; - iter237.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStartstrEndstr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.tend = input.readString(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstrEndstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 3); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.STRING, 4); - output.writeString(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_chronologizeKeyRecordStartstrEndstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3239 = input.readMapBegin(); - const _size238 = _rtmp3239.size || 0; - for (let _i240 = 0; _i240 < _size238; ++_i240) { - let key241 = null; - let val242 = null; - key241 = input.readI64(); - val242 = []; - const _rtmp3244 = input.readSetBegin(); - const _size243 = _rtmp3244.size || 0; - for (let _i245 = 0; _i245 < _size243; ++_i245) { - let elem246 = null; - elem246 = new data_ttypes.TObject(); - elem246.read(input); - val242.push(elem246); - } - input.readSetEnd(); - this.success[key241] = val242; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_chronologizeKeyRecordStartstrEndstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter247 in this.success) { - if (this.success.hasOwnProperty(kiter247)) { - let viter248 = this.success[kiter247]; - output.writeI64(kiter247); - output.writeSetBegin(Thrift.Type.STRUCT, viter248.length); - for (let iter249 in viter248) { - if (viter248.hasOwnProperty(iter249)) { - iter249 = viter248[iter249]; - iter249.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearRecord_args = class { - constructor(args) { - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearRecord_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearRecord_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearRecord_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearRecords_args = class { - constructor(args) { - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3251 = input.readListBegin(); - const _size250 = _rtmp3251.size || 0; - for (let _i252 = 0; _i252 < _size250; ++_i252) { - let elem253 = null; - elem253 = input.readI64(); - this.records.push(elem253); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearRecords_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter254 in this.records) { - if (this.records.hasOwnProperty(iter254)) { - iter254 = this.records[iter254]; - output.writeI64(iter254); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearRecords_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearRecords_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeyRecord_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeyRecord_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeysRecord_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3256 = input.readListBegin(); - const _size255 = _rtmp3256.size || 0; - for (let _i257 = 0; _i257 < _size255; ++_i257) { - let elem258 = null; - elem258 = input.readString(); - this.keys.push(elem258); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeysRecord_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter259 in this.keys) { - if (this.keys.hasOwnProperty(iter259)) { - iter259 = this.keys[iter259]; - output.writeString(iter259); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeysRecord_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeysRecord_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3261 = input.readListBegin(); - const _size260 = _rtmp3261.size || 0; - for (let _i262 = 0; _i262 < _size260; ++_i262) { - let elem263 = null; - elem263 = input.readI64(); - this.records.push(elem263); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter264 in this.records) { - if (this.records.hasOwnProperty(iter264)) { - iter264 = this.records[iter264]; - output.writeI64(iter264); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeyRecords_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeyRecords_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeysRecords_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3266 = input.readListBegin(); - const _size265 = _rtmp3266.size || 0; - for (let _i267 = 0; _i267 < _size265; ++_i267) { - let elem268 = null; - elem268 = input.readString(); - this.keys.push(elem268); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3270 = input.readListBegin(); - const _size269 = _rtmp3270.size || 0; - for (let _i271 = 0; _i271 < _size269; ++_i271) { - let elem272 = null; - elem272 = input.readI64(); - this.records.push(elem272); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeysRecords_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter273 in this.keys) { - if (this.keys.hasOwnProperty(iter273)) { - iter273 = this.keys[iter273]; - output.writeString(iter273); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter274 in this.records) { - if (this.records.hasOwnProperty(iter274)) { - iter274 = this.records[iter274]; - output.writeI64(iter274); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_clearKeysRecords_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_clearKeysRecords_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_commit_args = class { - constructor(args) { - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_commit_args'); - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 3); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_commit_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_commit_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describe_args = class { - constructor(args) { - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describe_args'); - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 3); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describe_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3276 = input.readSetBegin(); - const _size275 = _rtmp3276.size || 0; - for (let _i277 = 0; _i277 < _size275; ++_i277) { - let elem278 = null; - elem278 = input.readString(); - this.success.push(elem278); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describe_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRING, this.success.length); - for (let iter279 in this.success) { - if (this.success.hasOwnProperty(iter279)) { - iter279 = this.success[iter279]; - output.writeString(iter279); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeTime_args = class { - constructor(args) { - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeTime_args'); - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 1); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3281 = input.readSetBegin(); - const _size280 = _rtmp3281.size || 0; - for (let _i282 = 0; _i282 < _size280; ++_i282) { - let elem283 = null; - elem283 = input.readString(); - this.success.push(elem283); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRING, this.success.length); - for (let iter284 in this.success) { - if (this.success.hasOwnProperty(iter284)) { - iter284 = this.success[iter284]; - output.writeString(iter284); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeTimestr_args = class { - constructor(args) { - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeTimestr_args'); - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 1); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3286 = input.readSetBegin(); - const _size285 = _rtmp3286.size || 0; - for (let _i287 = 0; _i287 < _size285; ++_i287) { - let elem288 = null; - elem288 = input.readString(); - this.success.push(elem288); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRING, this.success.length); - for (let iter289 in this.success) { - if (this.success.hasOwnProperty(iter289)) { - iter289 = this.success[iter289]; - output.writeString(iter289); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecord_args = class { - constructor(args) { - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecord_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3291 = input.readSetBegin(); - const _size290 = _rtmp3291.size || 0; - for (let _i292 = 0; _i292 < _size290; ++_i292) { - let elem293 = null; - elem293 = input.readString(); - this.success.push(elem293); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRING, this.success.length); - for (let iter294 in this.success) { - if (this.success.hasOwnProperty(iter294)) { - iter294 = this.success[iter294]; - output.writeString(iter294); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordTime_args = class { - constructor(args) { - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordTime_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3296 = input.readSetBegin(); - const _size295 = _rtmp3296.size || 0; - for (let _i297 = 0; _i297 < _size295; ++_i297) { - let elem298 = null; - elem298 = input.readString(); - this.success.push(elem298); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRING, this.success.length); - for (let iter299 in this.success) { - if (this.success.hasOwnProperty(iter299)) { - iter299 = this.success[iter299]; - output.writeString(iter299); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordTimestr_args = class { - constructor(args) { - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordTimestr_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3301 = input.readSetBegin(); - const _size300 = _rtmp3301.size || 0; - for (let _i302 = 0; _i302 < _size300; ++_i302) { - let elem303 = null; - elem303 = input.readString(); - this.success.push(elem303); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRING, this.success.length); - for (let iter304 in this.success) { - if (this.success.hasOwnProperty(iter304)) { - iter304 = this.success[iter304]; - output.writeString(iter304); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecords_args = class { - constructor(args) { - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3306 = input.readListBegin(); - const _size305 = _rtmp3306.size || 0; - for (let _i307 = 0; _i307 < _size305; ++_i307) { - let elem308 = null; - elem308 = input.readI64(); - this.records.push(elem308); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecords_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter309 in this.records) { - if (this.records.hasOwnProperty(iter309)) { - iter309 = this.records[iter309]; - output.writeI64(iter309); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3311 = input.readMapBegin(); - const _size310 = _rtmp3311.size || 0; - for (let _i312 = 0; _i312 < _size310; ++_i312) { - let key313 = null; - let val314 = null; - key313 = input.readI64(); - val314 = []; - const _rtmp3316 = input.readSetBegin(); - const _size315 = _rtmp3316.size || 0; - for (let _i317 = 0; _i317 < _size315; ++_i317) { - let elem318 = null; - elem318 = input.readString(); - val314.push(elem318); - } - input.readSetEnd(); - this.success[key313] = val314; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter319 in this.success) { - if (this.success.hasOwnProperty(kiter319)) { - let viter320 = this.success[kiter319]; - output.writeI64(kiter319); - output.writeSetBegin(Thrift.Type.STRING, viter320.length); - for (let iter321 in viter320) { - if (viter320.hasOwnProperty(iter321)) { - iter321 = viter320[iter321]; - output.writeString(iter321); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordsTime_args = class { - constructor(args) { - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3323 = input.readListBegin(); - const _size322 = _rtmp3323.size || 0; - for (let _i324 = 0; _i324 < _size322; ++_i324) { - let elem325 = null; - elem325 = input.readI64(); - this.records.push(elem325); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordsTime_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter326 in this.records) { - if (this.records.hasOwnProperty(iter326)) { - iter326 = this.records[iter326]; - output.writeI64(iter326); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3328 = input.readMapBegin(); - const _size327 = _rtmp3328.size || 0; - for (let _i329 = 0; _i329 < _size327; ++_i329) { - let key330 = null; - let val331 = null; - key330 = input.readI64(); - val331 = []; - const _rtmp3333 = input.readSetBegin(); - const _size332 = _rtmp3333.size || 0; - for (let _i334 = 0; _i334 < _size332; ++_i334) { - let elem335 = null; - elem335 = input.readString(); - val331.push(elem335); - } - input.readSetEnd(); - this.success[key330] = val331; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter336 in this.success) { - if (this.success.hasOwnProperty(kiter336)) { - let viter337 = this.success[kiter336]; - output.writeI64(kiter336); - output.writeSetBegin(Thrift.Type.STRING, viter337.length); - for (let iter338 in viter337) { - if (viter337.hasOwnProperty(iter338)) { - iter338 = viter337[iter338]; - output.writeString(iter338); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordsTimestr_args = class { - constructor(args) { - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3340 = input.readListBegin(); - const _size339 = _rtmp3340.size || 0; - for (let _i341 = 0; _i341 < _size339; ++_i341) { - let elem342 = null; - elem342 = input.readI64(); - this.records.push(elem342); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordsTimestr_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter343 in this.records) { - if (this.records.hasOwnProperty(iter343)) { - iter343 = this.records[iter343]; - output.writeI64(iter343); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_describeRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3345 = input.readMapBegin(); - const _size344 = _rtmp3345.size || 0; - for (let _i346 = 0; _i346 < _size344; ++_i346) { - let key347 = null; - let val348 = null; - key347 = input.readI64(); - val348 = []; - const _rtmp3350 = input.readSetBegin(); - const _size349 = _rtmp3350.size || 0; - for (let _i351 = 0; _i351 < _size349; ++_i351) { - let elem352 = null; - elem352 = input.readString(); - val348.push(elem352); - } - input.readSetEnd(); - this.success[key347] = val348; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_describeRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter353 in this.success) { - if (this.success.hasOwnProperty(kiter353)) { - let viter354 = this.success[kiter353]; - output.writeI64(kiter353); - output.writeSetBegin(Thrift.Type.STRING, viter354.length); - for (let iter355 in viter354) { - if (viter354.hasOwnProperty(iter355)) { - iter355 = viter354[iter355]; - output.writeString(iter355); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStart_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStart_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 2); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStart_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3357 = input.readMapBegin(); - const _size356 = _rtmp3357.size || 0; - for (let _i358 = 0; _i358 < _size356; ++_i358) { - let key359 = null; - let val360 = null; - key359 = input.readString(); - val360 = {}; - const _rtmp3362 = input.readMapBegin(); - const _size361 = _rtmp3362.size || 0; - for (let _i363 = 0; _i363 < _size361; ++_i363) { - let key364 = null; - let val365 = null; - key364 = input.readI32(); - val365 = []; - const _rtmp3367 = input.readSetBegin(); - const _size366 = _rtmp3367.size || 0; - for (let _i368 = 0; _i368 < _size366; ++_i368) { - let elem369 = null; - elem369 = new data_ttypes.TObject(); - elem369.read(input); - val365.push(elem369); - } - input.readSetEnd(); - val360[key364] = val365; - } - input.readMapEnd(); - this.success[key359] = val360; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStart_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter370 in this.success) { - if (this.success.hasOwnProperty(kiter370)) { - let viter371 = this.success[kiter370]; - output.writeString(kiter370); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter371)); - for (let kiter372 in viter371) { - if (viter371.hasOwnProperty(kiter372)) { - let viter373 = viter371[kiter372]; - output.writeI32(kiter372); - output.writeSetBegin(Thrift.Type.STRUCT, viter373.length); - for (let iter374 in viter373) { - if (viter373.hasOwnProperty(iter374)) { - iter374 = viter373[iter374]; - iter374.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStartstr_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStartstr_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 2); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStartstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3376 = input.readMapBegin(); - const _size375 = _rtmp3376.size || 0; - for (let _i377 = 0; _i377 < _size375; ++_i377) { - let key378 = null; - let val379 = null; - key378 = input.readString(); - val379 = {}; - const _rtmp3381 = input.readMapBegin(); - const _size380 = _rtmp3381.size || 0; - for (let _i382 = 0; _i382 < _size380; ++_i382) { - let key383 = null; - let val384 = null; - key383 = input.readI32(); - val384 = []; - const _rtmp3386 = input.readSetBegin(); - const _size385 = _rtmp3386.size || 0; - for (let _i387 = 0; _i387 < _size385; ++_i387) { - let elem388 = null; - elem388 = new data_ttypes.TObject(); - elem388.read(input); - val384.push(elem388); - } - input.readSetEnd(); - val379[key383] = val384; - } - input.readMapEnd(); - this.success[key378] = val379; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStartstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter389 in this.success) { - if (this.success.hasOwnProperty(kiter389)) { - let viter390 = this.success[kiter389]; - output.writeString(kiter389); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter390)); - for (let kiter391 in viter390) { - if (viter390.hasOwnProperty(kiter391)) { - let viter392 = viter390[kiter391]; - output.writeI32(kiter391); - output.writeSetBegin(Thrift.Type.STRUCT, viter392.length); - for (let iter393 in viter392) { - if (viter392.hasOwnProperty(iter393)) { - iter393 = viter392[iter393]; - iter393.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStartEnd_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.tend = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStartEnd_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 2); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.I64, 3); - output.writeI64(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStartEnd_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3395 = input.readMapBegin(); - const _size394 = _rtmp3395.size || 0; - for (let _i396 = 0; _i396 < _size394; ++_i396) { - let key397 = null; - let val398 = null; - key397 = input.readString(); - val398 = {}; - const _rtmp3400 = input.readMapBegin(); - const _size399 = _rtmp3400.size || 0; - for (let _i401 = 0; _i401 < _size399; ++_i401) { - let key402 = null; - let val403 = null; - key402 = input.readI32(); - val403 = []; - const _rtmp3405 = input.readSetBegin(); - const _size404 = _rtmp3405.size || 0; - for (let _i406 = 0; _i406 < _size404; ++_i406) { - let elem407 = null; - elem407 = new data_ttypes.TObject(); - elem407.read(input); - val403.push(elem407); - } - input.readSetEnd(); - val398[key402] = val403; - } - input.readMapEnd(); - this.success[key397] = val398; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStartEnd_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter408 in this.success) { - if (this.success.hasOwnProperty(kiter408)) { - let viter409 = this.success[kiter408]; - output.writeString(kiter408); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter409)); - for (let kiter410 in viter409) { - if (viter409.hasOwnProperty(kiter410)) { - let viter411 = viter409[kiter410]; - output.writeI32(kiter410); - output.writeSetBegin(Thrift.Type.STRUCT, viter411.length); - for (let iter412 in viter411) { - if (viter411.hasOwnProperty(iter412)) { - iter412 = viter411[iter412]; - iter412.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStartstrEndstr_args = class { - constructor(args) { - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.tend = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStartstrEndstr_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 2); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.STRING, 3); - output.writeString(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffRecordStartstrEndstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3414 = input.readMapBegin(); - const _size413 = _rtmp3414.size || 0; - for (let _i415 = 0; _i415 < _size413; ++_i415) { - let key416 = null; - let val417 = null; - key416 = input.readString(); - val417 = {}; - const _rtmp3419 = input.readMapBegin(); - const _size418 = _rtmp3419.size || 0; - for (let _i420 = 0; _i420 < _size418; ++_i420) { - let key421 = null; - let val422 = null; - key421 = input.readI32(); - val422 = []; - const _rtmp3424 = input.readSetBegin(); - const _size423 = _rtmp3424.size || 0; - for (let _i425 = 0; _i425 < _size423; ++_i425) { - let elem426 = null; - elem426 = new data_ttypes.TObject(); - elem426.read(input); - val422.push(elem426); - } - input.readSetEnd(); - val417[key421] = val422; - } - input.readMapEnd(); - this.success[key416] = val417; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffRecordStartstrEndstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter427 in this.success) { - if (this.success.hasOwnProperty(kiter427)) { - let viter428 = this.success[kiter427]; - output.writeString(kiter427); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter428)); - for (let kiter429 in viter428) { - if (viter428.hasOwnProperty(kiter429)) { - let viter430 = viter428[kiter429]; - output.writeI32(kiter429); - output.writeSetBegin(Thrift.Type.STRUCT, viter430.length); - for (let iter431 in viter430) { - if (viter430.hasOwnProperty(iter431)) { - iter431 = viter430[iter431]; - iter431.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStart_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStart_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 3); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStart_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3433 = input.readMapBegin(); - const _size432 = _rtmp3433.size || 0; - for (let _i434 = 0; _i434 < _size432; ++_i434) { - let key435 = null; - let val436 = null; - key435 = input.readI32(); - val436 = []; - const _rtmp3438 = input.readSetBegin(); - const _size437 = _rtmp3438.size || 0; - for (let _i439 = 0; _i439 < _size437; ++_i439) { - let elem440 = null; - elem440 = new data_ttypes.TObject(); - elem440.read(input); - val436.push(elem440); - } - input.readSetEnd(); - this.success[key435] = val436; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStart_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter441 in this.success) { - if (this.success.hasOwnProperty(kiter441)) { - let viter442 = this.success[kiter441]; - output.writeI32(kiter441); - output.writeSetBegin(Thrift.Type.STRUCT, viter442.length); - for (let iter443 in viter442) { - if (viter442.hasOwnProperty(iter443)) { - iter443 = viter442[iter443]; - iter443.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStartstr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStartstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 3); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStartstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3445 = input.readMapBegin(); - const _size444 = _rtmp3445.size || 0; - for (let _i446 = 0; _i446 < _size444; ++_i446) { - let key447 = null; - let val448 = null; - key447 = input.readI32(); - val448 = []; - const _rtmp3450 = input.readSetBegin(); - const _size449 = _rtmp3450.size || 0; - for (let _i451 = 0; _i451 < _size449; ++_i451) { - let elem452 = null; - elem452 = new data_ttypes.TObject(); - elem452.read(input); - val448.push(elem452); - } - input.readSetEnd(); - this.success[key447] = val448; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStartstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter453 in this.success) { - if (this.success.hasOwnProperty(kiter453)) { - let viter454 = this.success[kiter453]; - output.writeI32(kiter453); - output.writeSetBegin(Thrift.Type.STRUCT, viter454.length); - for (let iter455 in viter454) { - if (viter454.hasOwnProperty(iter455)) { - iter455 = viter454[iter455]; - iter455.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStartEnd_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.I64) { - this.tend = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStartEnd_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 3); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.I64, 4); - output.writeI64(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStartEnd_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3457 = input.readMapBegin(); - const _size456 = _rtmp3457.size || 0; - for (let _i458 = 0; _i458 < _size456; ++_i458) { - let key459 = null; - let val460 = null; - key459 = input.readI32(); - val460 = []; - const _rtmp3462 = input.readSetBegin(); - const _size461 = _rtmp3462.size || 0; - for (let _i463 = 0; _i463 < _size461; ++_i463) { - let elem464 = null; - elem464 = new data_ttypes.TObject(); - elem464.read(input); - val460.push(elem464); - } - input.readSetEnd(); - this.success[key459] = val460; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStartEnd_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter465 in this.success) { - if (this.success.hasOwnProperty(kiter465)) { - let viter466 = this.success[kiter465]; - output.writeI32(kiter465); - output.writeSetBegin(Thrift.Type.STRUCT, viter466.length); - for (let iter467 in viter466) { - if (viter466.hasOwnProperty(iter467)) { - iter467 = viter466[iter467]; - iter467.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStartstrEndstr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.tend = input.readString(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStartstrEndstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 3); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.STRING, 4); - output.writeString(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyRecordStartstrEndstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3469 = input.readMapBegin(); - const _size468 = _rtmp3469.size || 0; - for (let _i470 = 0; _i470 < _size468; ++_i470) { - let key471 = null; - let val472 = null; - key471 = input.readI32(); - val472 = []; - const _rtmp3474 = input.readSetBegin(); - const _size473 = _rtmp3474.size || 0; - for (let _i475 = 0; _i475 < _size473; ++_i475) { - let elem476 = null; - elem476 = new data_ttypes.TObject(); - elem476.read(input); - val472.push(elem476); - } - input.readSetEnd(); - this.success[key471] = val472; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyRecordStartstrEndstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter477 in this.success) { - if (this.success.hasOwnProperty(kiter477)) { - let viter478 = this.success[kiter477]; - output.writeI32(kiter477); - output.writeSetBegin(Thrift.Type.STRUCT, viter478.length); - for (let iter479 in viter478) { - if (viter478.hasOwnProperty(iter479)) { - iter479 = viter478[iter479]; - iter479.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStart_args = class { - constructor(args) { - this.key = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStart_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 2); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStart_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3481 = input.readMapBegin(); - const _size480 = _rtmp3481.size || 0; - for (let _i482 = 0; _i482 < _size480; ++_i482) { - let key483 = null; - let val484 = null; - key483 = new data_ttypes.TObject(); - key483.read(input); - val484 = {}; - const _rtmp3486 = input.readMapBegin(); - const _size485 = _rtmp3486.size || 0; - for (let _i487 = 0; _i487 < _size485; ++_i487) { - let key488 = null; - let val489 = null; - key488 = input.readI32(); - val489 = []; - const _rtmp3491 = input.readSetBegin(); - const _size490 = _rtmp3491.size || 0; - for (let _i492 = 0; _i492 < _size490; ++_i492) { - let elem493 = null; - elem493 = input.readI64(); - val489.push(elem493); - } - input.readSetEnd(); - val484[key488] = val489; - } - input.readMapEnd(); - this.success[key483] = val484; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStart_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter494 in this.success) { - if (this.success.hasOwnProperty(kiter494)) { - let viter495 = this.success[kiter494]; - kiter494.write(output); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter495)); - for (let kiter496 in viter495) { - if (viter495.hasOwnProperty(kiter496)) { - let viter497 = viter495[kiter496]; - output.writeI32(kiter496); - output.writeSetBegin(Thrift.Type.I64, viter497.length); - for (let iter498 in viter497) { - if (viter497.hasOwnProperty(iter498)) { - iter498 = viter497[iter498]; - output.writeI64(iter498); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStartstr_args = class { - constructor(args) { - this.key = null; - this.start = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStartstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 2); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStartstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3500 = input.readMapBegin(); - const _size499 = _rtmp3500.size || 0; - for (let _i501 = 0; _i501 < _size499; ++_i501) { - let key502 = null; - let val503 = null; - key502 = new data_ttypes.TObject(); - key502.read(input); - val503 = {}; - const _rtmp3505 = input.readMapBegin(); - const _size504 = _rtmp3505.size || 0; - for (let _i506 = 0; _i506 < _size504; ++_i506) { - let key507 = null; - let val508 = null; - key507 = input.readI32(); - val508 = []; - const _rtmp3510 = input.readSetBegin(); - const _size509 = _rtmp3510.size || 0; - for (let _i511 = 0; _i511 < _size509; ++_i511) { - let elem512 = null; - elem512 = input.readI64(); - val508.push(elem512); - } - input.readSetEnd(); - val503[key507] = val508; - } - input.readMapEnd(); - this.success[key502] = val503; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStartstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter513 in this.success) { - if (this.success.hasOwnProperty(kiter513)) { - let viter514 = this.success[kiter513]; - kiter513.write(output); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter514)); - for (let kiter515 in viter514) { - if (viter514.hasOwnProperty(kiter515)) { - let viter516 = viter514[kiter515]; - output.writeI32(kiter515); - output.writeSetBegin(Thrift.Type.I64, viter516.length); - for (let iter517 in viter516) { - if (viter516.hasOwnProperty(iter517)) { - iter517 = viter516[iter517]; - output.writeI64(iter517); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStartEnd_args = class { - constructor(args) { - this.key = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.start = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.tend = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStartEnd_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.I64, 2); - output.writeI64(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.I64, 3); - output.writeI64(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStartEnd_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3519 = input.readMapBegin(); - const _size518 = _rtmp3519.size || 0; - for (let _i520 = 0; _i520 < _size518; ++_i520) { - let key521 = null; - let val522 = null; - key521 = new data_ttypes.TObject(); - key521.read(input); - val522 = {}; - const _rtmp3524 = input.readMapBegin(); - const _size523 = _rtmp3524.size || 0; - for (let _i525 = 0; _i525 < _size523; ++_i525) { - let key526 = null; - let val527 = null; - key526 = input.readI32(); - val527 = []; - const _rtmp3529 = input.readSetBegin(); - const _size528 = _rtmp3529.size || 0; - for (let _i530 = 0; _i530 < _size528; ++_i530) { - let elem531 = null; - elem531 = input.readI64(); - val527.push(elem531); - } - input.readSetEnd(); - val522[key526] = val527; - } - input.readMapEnd(); - this.success[key521] = val522; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStartEnd_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter532 in this.success) { - if (this.success.hasOwnProperty(kiter532)) { - let viter533 = this.success[kiter532]; - kiter532.write(output); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter533)); - for (let kiter534 in viter533) { - if (viter533.hasOwnProperty(kiter534)) { - let viter535 = viter533[kiter534]; - output.writeI32(kiter534); - output.writeSetBegin(Thrift.Type.I64, viter535.length); - for (let iter536 in viter535) { - if (viter535.hasOwnProperty(iter536)) { - iter536 = viter535[iter536]; - output.writeI64(iter536); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStartstrEndstr_args = class { - constructor(args) { - this.key = null; - this.start = null; - this.tend = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.start !== undefined && args.start !== null) { - this.start = args.start; - } - if (args.tend !== undefined && args.tend !== null) { - this.tend = args.tend; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.start = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.tend = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStartstrEndstr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.start !== null && this.start !== undefined) { - output.writeFieldBegin('start', Thrift.Type.STRING, 2); - output.writeString(this.start); - output.writeFieldEnd(); - } - if (this.tend !== null && this.tend !== undefined) { - output.writeFieldBegin('tend', Thrift.Type.STRING, 3); - output.writeString(this.tend); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_diffKeyStartstrEndstr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3538 = input.readMapBegin(); - const _size537 = _rtmp3538.size || 0; - for (let _i539 = 0; _i539 < _size537; ++_i539) { - let key540 = null; - let val541 = null; - key540 = new data_ttypes.TObject(); - key540.read(input); - val541 = {}; - const _rtmp3543 = input.readMapBegin(); - const _size542 = _rtmp3543.size || 0; - for (let _i544 = 0; _i544 < _size542; ++_i544) { - let key545 = null; - let val546 = null; - key545 = input.readI32(); - val546 = []; - const _rtmp3548 = input.readSetBegin(); - const _size547 = _rtmp3548.size || 0; - for (let _i549 = 0; _i549 < _size547; ++_i549) { - let elem550 = null; - elem550 = input.readI64(); - val546.push(elem550); - } - input.readSetEnd(); - val541[key545] = val546; - } - input.readMapEnd(); - this.success[key540] = val541; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_diffKeyStartstrEndstr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRUCT, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter551 in this.success) { - if (this.success.hasOwnProperty(kiter551)) { - let viter552 = this.success[kiter551]; - kiter551.write(output); - output.writeMapBegin(Thrift.Type.I32, Thrift.Type.SET, Thrift.objectLength(viter552)); - for (let kiter553 in viter552) { - if (viter552.hasOwnProperty(kiter553)) { - let viter554 = viter552[kiter553]; - output.writeI32(kiter553); - output.writeSetBegin(Thrift.Type.I64, viter554.length); - for (let iter555 in viter554) { - if (viter554.hasOwnProperty(iter555)) { - iter555 = viter554[iter555]; - output.writeI64(iter555); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_invokePlugin_args = class { - constructor(args) { - this.id = null; - this.method = null; - this.params = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.id !== undefined && args.id !== null) { - this.id = args.id; - } - if (args.method !== undefined && args.method !== null) { - this.method = args.method; - } - if (args.params !== undefined && args.params !== null) { - this.params = Thrift.copyList(args.params, [complex_ttypes.ComplexTObject]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.id = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.method = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.params = []; - const _rtmp3557 = input.readListBegin(); - const _size556 = _rtmp3557.size || 0; - for (let _i558 = 0; _i558 < _size556; ++_i558) { - let elem559 = null; - elem559 = new complex_ttypes.ComplexTObject(); - elem559.read(input); - this.params.push(elem559); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_invokePlugin_args'); - if (this.id !== null && this.id !== undefined) { - output.writeFieldBegin('id', Thrift.Type.STRING, 1); - output.writeString(this.id); - output.writeFieldEnd(); - } - if (this.method !== null && this.method !== undefined) { - output.writeFieldBegin('method', Thrift.Type.STRING, 2); - output.writeString(this.method); - output.writeFieldEnd(); - } - if (this.params !== null && this.params !== undefined) { - output.writeFieldBegin('params', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.params.length); - for (let iter560 in this.params) { - if (this.params.hasOwnProperty(iter560)) { - iter560 = this.params[iter560]; - iter560.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_invokePlugin_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new complex_ttypes.ComplexTObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new complex_ttypes.ComplexTObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_invokePlugin_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_login_args = class { - constructor(args) { - this.username = null; - this.password = null; - this.environment = null; - if (args) { - if (args.username !== undefined && args.username !== null) { - this.username = args.username; - } - if (args.password !== undefined && args.password !== null) { - this.password = args.password; - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.username = input.readBinary(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.password = input.readBinary(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_login_args'); - if (this.username !== null && this.username !== undefined) { - output.writeFieldBegin('username', Thrift.Type.STRING, 1); - output.writeBinary(this.username); - output.writeFieldEnd(); - } - if (this.password !== null && this.password !== undefined) { - output.writeFieldBegin('password', Thrift.Type.STRING, 2); - output.writeBinary(this.password); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 3); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_login_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex2 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new shared_ttypes.AccessToken(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new shared_ttypes.AccessToken(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.PermissionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_login_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_logout_args = class { - constructor(args) { - this.token = null; - this.environment = null; - if (args) { - if (args.token !== undefined && args.token !== null) { - this.token = new shared_ttypes.AccessToken(args.token); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.token = new shared_ttypes.AccessToken(); - this.token.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_logout_args'); - if (this.token !== null && this.token !== undefined) { - output.writeFieldBegin('token', Thrift.Type.STRUCT, 1); - this.token.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 2); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_logout_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex2 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.PermissionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_logout_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_stage_args = class { - constructor(args) { - this.token = null; - this.environment = null; - if (args) { - if (args.token !== undefined && args.token !== null) { - this.token = new shared_ttypes.AccessToken(args.token); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.token = new shared_ttypes.AccessToken(); - this.token.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_stage_args'); - if (this.token !== null && this.token !== undefined) { - output.writeFieldBegin('token', Thrift.Type.STRUCT, 1); - this.token.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 2); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_stage_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex2 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new shared_ttypes.TransactionToken(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new shared_ttypes.TransactionToken(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.PermissionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_stage_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_insertJson_args = class { - constructor(args) { - this.json = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.json !== undefined && args.json !== null) { - this.json = args.json; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.json = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_insertJson_args'); - if (this.json !== null && this.json !== undefined) { - output.writeFieldBegin('json', Thrift.Type.STRING, 1); - output.writeString(this.json); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_insertJson_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - this.ex5 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex4 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex5 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - if (args.ex5 !== undefined && args.ex5 !== null) { - this.ex5 = args.ex5; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3562 = input.readSetBegin(); - const _size561 = _rtmp3562.size || 0; - for (let _i563 = 0; _i563 < _size561; ++_i563) { - let elem564 = null; - elem564 = input.readI64(); - this.success.push(elem564); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.InvalidArgumentException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.ex5 = new exceptions_ttypes.PermissionException(); - this.ex5.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_insertJson_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter565 in this.success) { - if (this.success.hasOwnProperty(iter565)) { - iter565 = this.success[iter565]; - output.writeI64(iter565); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - if (this.ex5 !== null && this.ex5 !== undefined) { - output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); - this.ex5.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_insertJsonRecord_args = class { - constructor(args) { - this.json = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.json !== undefined && args.json !== null) { - this.json = args.json; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.json = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_insertJsonRecord_args'); - if (this.json !== null && this.json !== undefined) { - output.writeFieldBegin('json', Thrift.Type.STRING, 1); - output.writeString(this.json); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_insertJsonRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - this.ex5 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex4 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex5 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - if (args.ex5 !== undefined && args.ex5 !== null) { - this.ex5 = args.ex5; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.InvalidArgumentException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.ex5 = new exceptions_ttypes.PermissionException(); - this.ex5.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_insertJsonRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - if (this.ex5 !== null && this.ex5 !== undefined) { - output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); - this.ex5.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_insertJsonRecords_args = class { - constructor(args) { - this.json = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.json !== undefined && args.json !== null) { - this.json = args.json; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.json = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3567 = input.readListBegin(); - const _size566 = _rtmp3567.size || 0; - for (let _i568 = 0; _i568 < _size566; ++_i568) { - let elem569 = null; - elem569 = input.readI64(); - this.records.push(elem569); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_insertJsonRecords_args'); - if (this.json !== null && this.json !== undefined) { - output.writeFieldBegin('json', Thrift.Type.STRING, 1); - output.writeString(this.json); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter570 in this.records) { - if (this.records.hasOwnProperty(iter570)) { - iter570 = this.records[iter570]; - output.writeI64(iter570); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_insertJsonRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - this.ex5 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex4 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex5 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - if (args.ex5 !== undefined && args.ex5 !== null) { - this.ex5 = args.ex5; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3572 = input.readMapBegin(); - const _size571 = _rtmp3572.size || 0; - for (let _i573 = 0; _i573 < _size571; ++_i573) { - let key574 = null; - let val575 = null; - key574 = input.readI64(); - val575 = input.readBool(); - this.success[key574] = val575; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.InvalidArgumentException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.ex5 = new exceptions_ttypes.PermissionException(); - this.ex5.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_insertJsonRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); - for (let kiter576 in this.success) { - if (this.success.hasOwnProperty(kiter576)) { - let viter577 = this.success[kiter576]; - output.writeI64(kiter576); - output.writeBool(viter577); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - if (this.ex5 !== null && this.ex5 !== undefined) { - output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); - this.ex5.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_removeKeyValueRecord_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_removeKeyValueRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_removeKeyValueRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_removeKeyValueRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_removeKeyValueRecords_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3579 = input.readListBegin(); - const _size578 = _rtmp3579.size || 0; - for (let _i580 = 0; _i580 < _size578; ++_i580) { - let elem581 = null; - elem581 = input.readI64(); - this.records.push(elem581); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_removeKeyValueRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter582 in this.records) { - if (this.records.hasOwnProperty(iter582)) { - iter582 = this.records[iter582]; - output.writeI64(iter582); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_removeKeyValueRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3584 = input.readMapBegin(); - const _size583 = _rtmp3584.size || 0; - for (let _i585 = 0; _i585 < _size583; ++_i585) { - let key586 = null; - let val587 = null; - key586 = input.readI64(); - val587 = input.readBool(); - this.success[key586] = val587; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_removeKeyValueRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); - for (let kiter588 in this.success) { - if (this.success.hasOwnProperty(kiter588)) { - let viter589 = this.success[kiter588]; - output.writeI64(kiter588); - output.writeBool(viter589); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_setKeyValueRecord_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_setKeyValueRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_setKeyValueRecord_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_setKeyValueRecord_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_setKeyValue_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_setKeyValue_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_setKeyValue_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_setKeyValue_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_setKeyValueRecords_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3591 = input.readListBegin(); - const _size590 = _rtmp3591.size || 0; - for (let _i592 = 0; _i592 < _size590; ++_i592) { - let elem593 = null; - elem593 = input.readI64(); - this.records.push(elem593); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_setKeyValueRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter594 in this.records) { - if (this.records.hasOwnProperty(iter594)) { - iter594 = this.records[iter594]; - output.writeI64(iter594); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_setKeyValueRecords_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_setKeyValueRecords_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_reconcileKeyRecordValues_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.values = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.values !== undefined && args.values !== null) { - this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.SET) { - this.values = []; - const _rtmp3596 = input.readSetBegin(); - const _size595 = _rtmp3596.size || 0; - for (let _i597 = 0; _i597 < _size595; ++_i597) { - let elem598 = null; - elem598 = new data_ttypes.TObject(); - elem598.read(input); - this.values.push(elem598); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_reconcileKeyRecordValues_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.values !== null && this.values !== undefined) { - output.writeFieldBegin('values', Thrift.Type.SET, 3); - output.writeSetBegin(Thrift.Type.STRUCT, this.values.length); - for (let iter599 in this.values) { - if (this.values.hasOwnProperty(iter599)) { - iter599 = this.values[iter599]; - iter599.write(output); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_reconcileKeyRecordValues_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_reconcileKeyRecordValues_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_inventory_args = class { - constructor(args) { - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_inventory_args'); - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 2); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 3); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_inventory_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3601 = input.readSetBegin(); - const _size600 = _rtmp3601.size || 0; - for (let _i602 = 0; _i602 < _size600; ++_i602) { - let elem603 = null; - elem603 = input.readI64(); - this.success.push(elem603); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_inventory_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter604 in this.success) { - if (this.success.hasOwnProperty(iter604)) { - iter604 = this.success[iter604]; - output.writeI64(iter604); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecord_args = class { - constructor(args) { - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecord_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3606 = input.readMapBegin(); - const _size605 = _rtmp3606.size || 0; - for (let _i607 = 0; _i607 < _size605; ++_i607) { - let key608 = null; - let val609 = null; - key608 = input.readString(); - val609 = []; - const _rtmp3611 = input.readSetBegin(); - const _size610 = _rtmp3611.size || 0; - for (let _i612 = 0; _i612 < _size610; ++_i612) { - let elem613 = null; - elem613 = new data_ttypes.TObject(); - elem613.read(input); - val609.push(elem613); - } - input.readSetEnd(); - this.success[key608] = val609; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter614 in this.success) { - if (this.success.hasOwnProperty(kiter614)) { - let viter615 = this.success[kiter614]; - output.writeString(kiter614); - output.writeSetBegin(Thrift.Type.STRUCT, viter615.length); - for (let iter616 in viter615) { - if (viter615.hasOwnProperty(iter616)) { - iter616 = viter615[iter616]; - iter616.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecords_args = class { - constructor(args) { - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3618 = input.readListBegin(); - const _size617 = _rtmp3618.size || 0; - for (let _i619 = 0; _i619 < _size617; ++_i619) { - let elem620 = null; - elem620 = input.readI64(); - this.records.push(elem620); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecords_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter621 in this.records) { - if (this.records.hasOwnProperty(iter621)) { - iter621 = this.records[iter621]; - output.writeI64(iter621); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3623 = input.readMapBegin(); - const _size622 = _rtmp3623.size || 0; - for (let _i624 = 0; _i624 < _size622; ++_i624) { - let key625 = null; - let val626 = null; - key625 = input.readI64(); - val626 = {}; - const _rtmp3628 = input.readMapBegin(); - const _size627 = _rtmp3628.size || 0; - for (let _i629 = 0; _i629 < _size627; ++_i629) { - let key630 = null; - let val631 = null; - key630 = input.readString(); - val631 = []; - const _rtmp3633 = input.readSetBegin(); - const _size632 = _rtmp3633.size || 0; - for (let _i634 = 0; _i634 < _size632; ++_i634) { - let elem635 = null; - elem635 = new data_ttypes.TObject(); - elem635.read(input); - val631.push(elem635); - } - input.readSetEnd(); - val626[key630] = val631; - } - input.readMapEnd(); - this.success[key625] = val626; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter636 in this.success) { - if (this.success.hasOwnProperty(kiter636)) { - let viter637 = this.success[kiter636]; - output.writeI64(kiter636); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter637)); - for (let kiter638 in viter637) { - if (viter637.hasOwnProperty(kiter638)) { - let viter639 = viter637[kiter638]; - output.writeString(kiter638); - output.writeSetBegin(Thrift.Type.STRUCT, viter639.length); - for (let iter640 in viter639) { - if (viter639.hasOwnProperty(iter640)) { - iter640 = viter639[iter640]; - iter640.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordTime_args = class { - constructor(args) { - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordTime_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3642 = input.readMapBegin(); - const _size641 = _rtmp3642.size || 0; - for (let _i643 = 0; _i643 < _size641; ++_i643) { - let key644 = null; - let val645 = null; - key644 = input.readString(); - val645 = []; - const _rtmp3647 = input.readSetBegin(); - const _size646 = _rtmp3647.size || 0; - for (let _i648 = 0; _i648 < _size646; ++_i648) { - let elem649 = null; - elem649 = new data_ttypes.TObject(); - elem649.read(input); - val645.push(elem649); - } - input.readSetEnd(); - this.success[key644] = val645; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter650 in this.success) { - if (this.success.hasOwnProperty(kiter650)) { - let viter651 = this.success[kiter650]; - output.writeString(kiter650); - output.writeSetBegin(Thrift.Type.STRUCT, viter651.length); - for (let iter652 in viter651) { - if (viter651.hasOwnProperty(iter652)) { - iter652 = viter651[iter652]; - iter652.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordTimestr_args = class { - constructor(args) { - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordTimestr_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3654 = input.readMapBegin(); - const _size653 = _rtmp3654.size || 0; - for (let _i655 = 0; _i655 < _size653; ++_i655) { - let key656 = null; - let val657 = null; - key656 = input.readString(); - val657 = []; - const _rtmp3659 = input.readSetBegin(); - const _size658 = _rtmp3659.size || 0; - for (let _i660 = 0; _i660 < _size658; ++_i660) { - let elem661 = null; - elem661 = new data_ttypes.TObject(); - elem661.read(input); - val657.push(elem661); - } - input.readSetEnd(); - this.success[key656] = val657; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter662 in this.success) { - if (this.success.hasOwnProperty(kiter662)) { - let viter663 = this.success[kiter662]; - output.writeString(kiter662); - output.writeSetBegin(Thrift.Type.STRUCT, viter663.length); - for (let iter664 in viter663) { - if (viter663.hasOwnProperty(iter664)) { - iter664 = viter663[iter664]; - iter664.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordsTime_args = class { - constructor(args) { - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3666 = input.readListBegin(); - const _size665 = _rtmp3666.size || 0; - for (let _i667 = 0; _i667 < _size665; ++_i667) { - let elem668 = null; - elem668 = input.readI64(); - this.records.push(elem668); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordsTime_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter669 in this.records) { - if (this.records.hasOwnProperty(iter669)) { - iter669 = this.records[iter669]; - output.writeI64(iter669); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3671 = input.readMapBegin(); - const _size670 = _rtmp3671.size || 0; - for (let _i672 = 0; _i672 < _size670; ++_i672) { - let key673 = null; - let val674 = null; - key673 = input.readI64(); - val674 = {}; - const _rtmp3676 = input.readMapBegin(); - const _size675 = _rtmp3676.size || 0; - for (let _i677 = 0; _i677 < _size675; ++_i677) { - let key678 = null; - let val679 = null; - key678 = input.readString(); - val679 = []; - const _rtmp3681 = input.readSetBegin(); - const _size680 = _rtmp3681.size || 0; - for (let _i682 = 0; _i682 < _size680; ++_i682) { - let elem683 = null; - elem683 = new data_ttypes.TObject(); - elem683.read(input); - val679.push(elem683); - } - input.readSetEnd(); - val674[key678] = val679; - } - input.readMapEnd(); - this.success[key673] = val674; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter684 in this.success) { - if (this.success.hasOwnProperty(kiter684)) { - let viter685 = this.success[kiter684]; - output.writeI64(kiter684); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter685)); - for (let kiter686 in viter685) { - if (viter685.hasOwnProperty(kiter686)) { - let viter687 = viter685[kiter686]; - output.writeString(kiter686); - output.writeSetBegin(Thrift.Type.STRUCT, viter687.length); - for (let iter688 in viter687) { - if (viter687.hasOwnProperty(iter688)) { - iter688 = viter687[iter688]; - iter688.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordsTimestr_args = class { - constructor(args) { - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3690 = input.readListBegin(); - const _size689 = _rtmp3690.size || 0; - for (let _i691 = 0; _i691 < _size689; ++_i691) { - let elem692 = null; - elem692 = input.readI64(); - this.records.push(elem692); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordsTimestr_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter693 in this.records) { - if (this.records.hasOwnProperty(iter693)) { - iter693 = this.records[iter693]; - output.writeI64(iter693); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3695 = input.readMapBegin(); - const _size694 = _rtmp3695.size || 0; - for (let _i696 = 0; _i696 < _size694; ++_i696) { - let key697 = null; - let val698 = null; - key697 = input.readI64(); - val698 = {}; - const _rtmp3700 = input.readMapBegin(); - const _size699 = _rtmp3700.size || 0; - for (let _i701 = 0; _i701 < _size699; ++_i701) { - let key702 = null; - let val703 = null; - key702 = input.readString(); - val703 = []; - const _rtmp3705 = input.readSetBegin(); - const _size704 = _rtmp3705.size || 0; - for (let _i706 = 0; _i706 < _size704; ++_i706) { - let elem707 = null; - elem707 = new data_ttypes.TObject(); - elem707.read(input); - val703.push(elem707); - } - input.readSetEnd(); - val698[key702] = val703; - } - input.readMapEnd(); - this.success[key697] = val698; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter708 in this.success) { - if (this.success.hasOwnProperty(kiter708)) { - let viter709 = this.success[kiter708]; - output.writeI64(kiter708); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter709)); - for (let kiter710 in viter709) { - if (viter709.hasOwnProperty(kiter710)) { - let viter711 = viter709[kiter710]; - output.writeString(kiter710); - output.writeSetBegin(Thrift.Type.STRUCT, viter711.length); - for (let iter712 in viter711) { - if (viter711.hasOwnProperty(iter712)) { - iter712 = viter711[iter712]; - iter712.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3714 = input.readSetBegin(); - const _size713 = _rtmp3714.size || 0; - for (let _i715 = 0; _i715 < _size713; ++_i715) { - let elem716 = null; - elem716 = new data_ttypes.TObject(); - elem716.read(input); - this.success.push(elem716); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRUCT, this.success.length); - for (let iter717 in this.success) { - if (this.success.hasOwnProperty(iter717)) { - iter717 = this.success[iter717]; - iter717.write(output); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3719 = input.readSetBegin(); - const _size718 = _rtmp3719.size || 0; - for (let _i720 = 0; _i720 < _size718; ++_i720) { - let elem721 = null; - elem721 = new data_ttypes.TObject(); - elem721.read(input); - this.success.push(elem721); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRUCT, this.success.length); - for (let iter722 in this.success) { - if (this.success.hasOwnProperty(iter722)) { - iter722 = this.success[iter722]; - iter722.write(output); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp3724 = input.readSetBegin(); - const _size723 = _rtmp3724.size || 0; - for (let _i725 = 0; _i725 < _size723; ++_i725) { - let elem726 = null; - elem726 = new data_ttypes.TObject(); - elem726.read(input); - this.success.push(elem726); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.STRUCT, this.success.length); - for (let iter727 in this.success) { - if (this.success.hasOwnProperty(iter727)) { - iter727 = this.success[iter727]; - iter727.write(output); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecord_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3729 = input.readListBegin(); - const _size728 = _rtmp3729.size || 0; - for (let _i730 = 0; _i730 < _size728; ++_i730) { - let elem731 = null; - elem731 = input.readString(); - this.keys.push(elem731); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecord_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter732 in this.keys) { - if (this.keys.hasOwnProperty(iter732)) { - iter732 = this.keys[iter732]; - output.writeString(iter732); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3734 = input.readMapBegin(); - const _size733 = _rtmp3734.size || 0; - for (let _i735 = 0; _i735 < _size733; ++_i735) { - let key736 = null; - let val737 = null; - key736 = input.readString(); - val737 = []; - const _rtmp3739 = input.readSetBegin(); - const _size738 = _rtmp3739.size || 0; - for (let _i740 = 0; _i740 < _size738; ++_i740) { - let elem741 = null; - elem741 = new data_ttypes.TObject(); - elem741.read(input); - val737.push(elem741); - } - input.readSetEnd(); - this.success[key736] = val737; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter742 in this.success) { - if (this.success.hasOwnProperty(kiter742)) { - let viter743 = this.success[kiter742]; - output.writeString(kiter742); - output.writeSetBegin(Thrift.Type.STRUCT, viter743.length); - for (let iter744 in viter743) { - if (viter743.hasOwnProperty(iter744)) { - iter744 = viter743[iter744]; - iter744.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordTime_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3746 = input.readListBegin(); - const _size745 = _rtmp3746.size || 0; - for (let _i747 = 0; _i747 < _size745; ++_i747) { - let elem748 = null; - elem748 = input.readString(); - this.keys.push(elem748); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter749 in this.keys) { - if (this.keys.hasOwnProperty(iter749)) { - iter749 = this.keys[iter749]; - output.writeString(iter749); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3751 = input.readMapBegin(); - const _size750 = _rtmp3751.size || 0; - for (let _i752 = 0; _i752 < _size750; ++_i752) { - let key753 = null; - let val754 = null; - key753 = input.readString(); - val754 = []; - const _rtmp3756 = input.readSetBegin(); - const _size755 = _rtmp3756.size || 0; - for (let _i757 = 0; _i757 < _size755; ++_i757) { - let elem758 = null; - elem758 = new data_ttypes.TObject(); - elem758.read(input); - val754.push(elem758); - } - input.readSetEnd(); - this.success[key753] = val754; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter759 in this.success) { - if (this.success.hasOwnProperty(kiter759)) { - let viter760 = this.success[kiter759]; - output.writeString(kiter759); - output.writeSetBegin(Thrift.Type.STRUCT, viter760.length); - for (let iter761 in viter760) { - if (viter760.hasOwnProperty(iter761)) { - iter761 = viter760[iter761]; - iter761.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordTimestr_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3763 = input.readListBegin(); - const _size762 = _rtmp3763.size || 0; - for (let _i764 = 0; _i764 < _size762; ++_i764) { - let elem765 = null; - elem765 = input.readString(); - this.keys.push(elem765); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter766 in this.keys) { - if (this.keys.hasOwnProperty(iter766)) { - iter766 = this.keys[iter766]; - output.writeString(iter766); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3768 = input.readMapBegin(); - const _size767 = _rtmp3768.size || 0; - for (let _i769 = 0; _i769 < _size767; ++_i769) { - let key770 = null; - let val771 = null; - key770 = input.readString(); - val771 = []; - const _rtmp3773 = input.readSetBegin(); - const _size772 = _rtmp3773.size || 0; - for (let _i774 = 0; _i774 < _size772; ++_i774) { - let elem775 = null; - elem775 = new data_ttypes.TObject(); - elem775.read(input); - val771.push(elem775); - } - input.readSetEnd(); - this.success[key770] = val771; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter776 in this.success) { - if (this.success.hasOwnProperty(kiter776)) { - let viter777 = this.success[kiter776]; - output.writeString(kiter776); - output.writeSetBegin(Thrift.Type.STRUCT, viter777.length); - for (let iter778 in viter777) { - if (viter777.hasOwnProperty(iter778)) { - iter778 = viter777[iter778]; - iter778.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecords_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3780 = input.readListBegin(); - const _size779 = _rtmp3780.size || 0; - for (let _i781 = 0; _i781 < _size779; ++_i781) { - let elem782 = null; - elem782 = input.readString(); - this.keys.push(elem782); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3784 = input.readListBegin(); - const _size783 = _rtmp3784.size || 0; - for (let _i785 = 0; _i785 < _size783; ++_i785) { - let elem786 = null; - elem786 = input.readI64(); - this.records.push(elem786); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecords_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter787 in this.keys) { - if (this.keys.hasOwnProperty(iter787)) { - iter787 = this.keys[iter787]; - output.writeString(iter787); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter788 in this.records) { - if (this.records.hasOwnProperty(iter788)) { - iter788 = this.records[iter788]; - output.writeI64(iter788); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3790 = input.readMapBegin(); - const _size789 = _rtmp3790.size || 0; - for (let _i791 = 0; _i791 < _size789; ++_i791) { - let key792 = null; - let val793 = null; - key792 = input.readI64(); - val793 = {}; - const _rtmp3795 = input.readMapBegin(); - const _size794 = _rtmp3795.size || 0; - for (let _i796 = 0; _i796 < _size794; ++_i796) { - let key797 = null; - let val798 = null; - key797 = input.readString(); - val798 = []; - const _rtmp3800 = input.readSetBegin(); - const _size799 = _rtmp3800.size || 0; - for (let _i801 = 0; _i801 < _size799; ++_i801) { - let elem802 = null; - elem802 = new data_ttypes.TObject(); - elem802.read(input); - val798.push(elem802); - } - input.readSetEnd(); - val793[key797] = val798; - } - input.readMapEnd(); - this.success[key792] = val793; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter803 in this.success) { - if (this.success.hasOwnProperty(kiter803)) { - let viter804 = this.success[kiter803]; - output.writeI64(kiter803); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter804)); - for (let kiter805 in viter804) { - if (viter804.hasOwnProperty(kiter805)) { - let viter806 = viter804[kiter805]; - output.writeString(kiter805); - output.writeSetBegin(Thrift.Type.STRUCT, viter806.length); - for (let iter807 in viter806) { - if (viter806.hasOwnProperty(iter807)) { - iter807 = viter806[iter807]; - iter807.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3809 = input.readListBegin(); - const _size808 = _rtmp3809.size || 0; - for (let _i810 = 0; _i810 < _size808; ++_i810) { - let elem811 = null; - elem811 = input.readI64(); - this.records.push(elem811); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter812 in this.records) { - if (this.records.hasOwnProperty(iter812)) { - iter812 = this.records[iter812]; - output.writeI64(iter812); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3814 = input.readMapBegin(); - const _size813 = _rtmp3814.size || 0; - for (let _i815 = 0; _i815 < _size813; ++_i815) { - let key816 = null; - let val817 = null; - key816 = input.readI64(); - val817 = []; - const _rtmp3819 = input.readSetBegin(); - const _size818 = _rtmp3819.size || 0; - for (let _i820 = 0; _i820 < _size818; ++_i820) { - let elem821 = null; - elem821 = new data_ttypes.TObject(); - elem821.read(input); - val817.push(elem821); - } - input.readSetEnd(); - this.success[key816] = val817; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter822 in this.success) { - if (this.success.hasOwnProperty(kiter822)) { - let viter823 = this.success[kiter822]; - output.writeI64(kiter822); - output.writeSetBegin(Thrift.Type.STRUCT, viter823.length); - for (let iter824 in viter823) { - if (viter823.hasOwnProperty(iter824)) { - iter824 = viter823[iter824]; - iter824.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3826 = input.readListBegin(); - const _size825 = _rtmp3826.size || 0; - for (let _i827 = 0; _i827 < _size825; ++_i827) { - let elem828 = null; - elem828 = input.readI64(); - this.records.push(elem828); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter829 in this.records) { - if (this.records.hasOwnProperty(iter829)) { - iter829 = this.records[iter829]; - output.writeI64(iter829); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3831 = input.readMapBegin(); - const _size830 = _rtmp3831.size || 0; - for (let _i832 = 0; _i832 < _size830; ++_i832) { - let key833 = null; - let val834 = null; - key833 = input.readI64(); - val834 = []; - const _rtmp3836 = input.readSetBegin(); - const _size835 = _rtmp3836.size || 0; - for (let _i837 = 0; _i837 < _size835; ++_i837) { - let elem838 = null; - elem838 = new data_ttypes.TObject(); - elem838.read(input); - val834.push(elem838); - } - input.readSetEnd(); - this.success[key833] = val834; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter839 in this.success) { - if (this.success.hasOwnProperty(kiter839)) { - let viter840 = this.success[kiter839]; - output.writeI64(kiter839); - output.writeSetBegin(Thrift.Type.STRUCT, viter840.length); - for (let iter841 in viter840) { - if (viter840.hasOwnProperty(iter841)) { - iter841 = viter840[iter841]; - iter841.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3843 = input.readListBegin(); - const _size842 = _rtmp3843.size || 0; - for (let _i844 = 0; _i844 < _size842; ++_i844) { - let elem845 = null; - elem845 = input.readI64(); - this.records.push(elem845); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter846 in this.records) { - if (this.records.hasOwnProperty(iter846)) { - iter846 = this.records[iter846]; - output.writeI64(iter846); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3848 = input.readMapBegin(); - const _size847 = _rtmp3848.size || 0; - for (let _i849 = 0; _i849 < _size847; ++_i849) { - let key850 = null; - let val851 = null; - key850 = input.readI64(); - val851 = []; - const _rtmp3853 = input.readSetBegin(); - const _size852 = _rtmp3853.size || 0; - for (let _i854 = 0; _i854 < _size852; ++_i854) { - let elem855 = null; - elem855 = new data_ttypes.TObject(); - elem855.read(input); - val851.push(elem855); - } - input.readSetEnd(); - this.success[key850] = val851; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter856 in this.success) { - if (this.success.hasOwnProperty(kiter856)) { - let viter857 = this.success[kiter856]; - output.writeI64(kiter856); - output.writeSetBegin(Thrift.Type.STRUCT, viter857.length); - for (let iter858 in viter857) { - if (viter857.hasOwnProperty(iter858)) { - iter858 = viter857[iter858]; - iter858.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordsTime_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3860 = input.readListBegin(); - const _size859 = _rtmp3860.size || 0; - for (let _i861 = 0; _i861 < _size859; ++_i861) { - let elem862 = null; - elem862 = input.readString(); - this.keys.push(elem862); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3864 = input.readListBegin(); - const _size863 = _rtmp3864.size || 0; - for (let _i865 = 0; _i865 < _size863; ++_i865) { - let elem866 = null; - elem866 = input.readI64(); - this.records.push(elem866); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordsTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter867 in this.keys) { - if (this.keys.hasOwnProperty(iter867)) { - iter867 = this.keys[iter867]; - output.writeString(iter867); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter868 in this.records) { - if (this.records.hasOwnProperty(iter868)) { - iter868 = this.records[iter868]; - output.writeI64(iter868); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3870 = input.readMapBegin(); - const _size869 = _rtmp3870.size || 0; - for (let _i871 = 0; _i871 < _size869; ++_i871) { - let key872 = null; - let val873 = null; - key872 = input.readI64(); - val873 = {}; - const _rtmp3875 = input.readMapBegin(); - const _size874 = _rtmp3875.size || 0; - for (let _i876 = 0; _i876 < _size874; ++_i876) { - let key877 = null; - let val878 = null; - key877 = input.readString(); - val878 = []; - const _rtmp3880 = input.readSetBegin(); - const _size879 = _rtmp3880.size || 0; - for (let _i881 = 0; _i881 < _size879; ++_i881) { - let elem882 = null; - elem882 = new data_ttypes.TObject(); - elem882.read(input); - val878.push(elem882); - } - input.readSetEnd(); - val873[key877] = val878; - } - input.readMapEnd(); - this.success[key872] = val873; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter883 in this.success) { - if (this.success.hasOwnProperty(kiter883)) { - let viter884 = this.success[kiter883]; - output.writeI64(kiter883); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter884)); - for (let kiter885 in viter884) { - if (viter884.hasOwnProperty(kiter885)) { - let viter886 = viter884[kiter885]; - output.writeString(kiter885); - output.writeSetBegin(Thrift.Type.STRUCT, viter886.length); - for (let iter887 in viter886) { - if (viter886.hasOwnProperty(iter887)) { - iter887 = viter886[iter887]; - iter887.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordsTimestr_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp3889 = input.readListBegin(); - const _size888 = _rtmp3889.size || 0; - for (let _i890 = 0; _i890 < _size888; ++_i890) { - let elem891 = null; - elem891 = input.readString(); - this.keys.push(elem891); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp3893 = input.readListBegin(); - const _size892 = _rtmp3893.size || 0; - for (let _i894 = 0; _i894 < _size892; ++_i894) { - let elem895 = null; - elem895 = input.readI64(); - this.records.push(elem895); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordsTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter896 in this.keys) { - if (this.keys.hasOwnProperty(iter896)) { - iter896 = this.keys[iter896]; - output.writeString(iter896); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter897 in this.records) { - if (this.records.hasOwnProperty(iter897)) { - iter897 = this.records[iter897]; - output.writeI64(iter897); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3899 = input.readMapBegin(); - const _size898 = _rtmp3899.size || 0; - for (let _i900 = 0; _i900 < _size898; ++_i900) { - let key901 = null; - let val902 = null; - key901 = input.readI64(); - val902 = {}; - const _rtmp3904 = input.readMapBegin(); - const _size903 = _rtmp3904.size || 0; - for (let _i905 = 0; _i905 < _size903; ++_i905) { - let key906 = null; - let val907 = null; - key906 = input.readString(); - val907 = []; - const _rtmp3909 = input.readSetBegin(); - const _size908 = _rtmp3909.size || 0; - for (let _i910 = 0; _i910 < _size908; ++_i910) { - let elem911 = null; - elem911 = new data_ttypes.TObject(); - elem911.read(input); - val907.push(elem911); - } - input.readSetEnd(); - val902[key906] = val907; - } - input.readMapEnd(); - this.success[key901] = val902; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter912 in this.success) { - if (this.success.hasOwnProperty(kiter912)) { - let viter913 = this.success[kiter912]; - output.writeI64(kiter912); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter913)); - for (let kiter914 in viter913) { - if (viter913.hasOwnProperty(kiter914)) { - let viter915 = viter913[kiter914]; - output.writeString(kiter914); - output.writeSetBegin(Thrift.Type.STRUCT, viter915.length); - for (let iter916 in viter915) { - if (viter915.hasOwnProperty(iter916)) { - iter916 = viter915[iter916]; - iter916.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCriteria_args = class { - constructor(args) { - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCriteria_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3918 = input.readMapBegin(); - const _size917 = _rtmp3918.size || 0; - for (let _i919 = 0; _i919 < _size917; ++_i919) { - let key920 = null; - let val921 = null; - key920 = input.readI64(); - val921 = {}; - const _rtmp3923 = input.readMapBegin(); - const _size922 = _rtmp3923.size || 0; - for (let _i924 = 0; _i924 < _size922; ++_i924) { - let key925 = null; - let val926 = null; - key925 = input.readString(); - val926 = []; - const _rtmp3928 = input.readSetBegin(); - const _size927 = _rtmp3928.size || 0; - for (let _i929 = 0; _i929 < _size927; ++_i929) { - let elem930 = null; - elem930 = new data_ttypes.TObject(); - elem930.read(input); - val926.push(elem930); - } - input.readSetEnd(); - val921[key925] = val926; - } - input.readMapEnd(); - this.success[key920] = val921; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter931 in this.success) { - if (this.success.hasOwnProperty(kiter931)) { - let viter932 = this.success[kiter931]; - output.writeI64(kiter931); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter932)); - for (let kiter933 in viter932) { - if (viter932.hasOwnProperty(kiter933)) { - let viter934 = viter932[kiter933]; - output.writeString(kiter933); - output.writeSetBegin(Thrift.Type.STRUCT, viter934.length); - for (let iter935 in viter934) { - if (viter934.hasOwnProperty(iter935)) { - iter935 = viter934[iter935]; - iter935.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCcl_args = class { - constructor(args) { - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCcl_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3937 = input.readMapBegin(); - const _size936 = _rtmp3937.size || 0; - for (let _i938 = 0; _i938 < _size936; ++_i938) { - let key939 = null; - let val940 = null; - key939 = input.readI64(); - val940 = {}; - const _rtmp3942 = input.readMapBegin(); - const _size941 = _rtmp3942.size || 0; - for (let _i943 = 0; _i943 < _size941; ++_i943) { - let key944 = null; - let val945 = null; - key944 = input.readString(); - val945 = []; - const _rtmp3947 = input.readSetBegin(); - const _size946 = _rtmp3947.size || 0; - for (let _i948 = 0; _i948 < _size946; ++_i948) { - let elem949 = null; - elem949 = new data_ttypes.TObject(); - elem949.read(input); - val945.push(elem949); - } - input.readSetEnd(); - val940[key944] = val945; - } - input.readMapEnd(); - this.success[key939] = val940; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter950 in this.success) { - if (this.success.hasOwnProperty(kiter950)) { - let viter951 = this.success[kiter950]; - output.writeI64(kiter950); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter951)); - for (let kiter952 in viter951) { - if (viter951.hasOwnProperty(kiter952)) { - let viter953 = viter951[kiter952]; - output.writeString(kiter952); - output.writeSetBegin(Thrift.Type.STRUCT, viter953.length); - for (let iter954 in viter953) { - if (viter953.hasOwnProperty(iter954)) { - iter954 = viter953[iter954]; - iter954.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCriteriaTime_args = class { - constructor(args) { - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCriteriaTime_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3956 = input.readMapBegin(); - const _size955 = _rtmp3956.size || 0; - for (let _i957 = 0; _i957 < _size955; ++_i957) { - let key958 = null; - let val959 = null; - key958 = input.readI64(); - val959 = {}; - const _rtmp3961 = input.readMapBegin(); - const _size960 = _rtmp3961.size || 0; - for (let _i962 = 0; _i962 < _size960; ++_i962) { - let key963 = null; - let val964 = null; - key963 = input.readString(); - val964 = []; - const _rtmp3966 = input.readSetBegin(); - const _size965 = _rtmp3966.size || 0; - for (let _i967 = 0; _i967 < _size965; ++_i967) { - let elem968 = null; - elem968 = new data_ttypes.TObject(); - elem968.read(input); - val964.push(elem968); - } - input.readSetEnd(); - val959[key963] = val964; - } - input.readMapEnd(); - this.success[key958] = val959; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter969 in this.success) { - if (this.success.hasOwnProperty(kiter969)) { - let viter970 = this.success[kiter969]; - output.writeI64(kiter969); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter970)); - for (let kiter971 in viter970) { - if (viter970.hasOwnProperty(kiter971)) { - let viter972 = viter970[kiter971]; - output.writeString(kiter971); - output.writeSetBegin(Thrift.Type.STRUCT, viter972.length); - for (let iter973 in viter972) { - if (viter972.hasOwnProperty(iter973)) { - iter973 = viter972[iter973]; - iter973.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCriteriaTimestr_args = class { - constructor(args) { - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCriteriaTimestr_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3975 = input.readMapBegin(); - const _size974 = _rtmp3975.size || 0; - for (let _i976 = 0; _i976 < _size974; ++_i976) { - let key977 = null; - let val978 = null; - key977 = input.readI64(); - val978 = {}; - const _rtmp3980 = input.readMapBegin(); - const _size979 = _rtmp3980.size || 0; - for (let _i981 = 0; _i981 < _size979; ++_i981) { - let key982 = null; - let val983 = null; - key982 = input.readString(); - val983 = []; - const _rtmp3985 = input.readSetBegin(); - const _size984 = _rtmp3985.size || 0; - for (let _i986 = 0; _i986 < _size984; ++_i986) { - let elem987 = null; - elem987 = new data_ttypes.TObject(); - elem987.read(input); - val983.push(elem987); - } - input.readSetEnd(); - val978[key982] = val983; - } - input.readMapEnd(); - this.success[key977] = val978; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter988 in this.success) { - if (this.success.hasOwnProperty(kiter988)) { - let viter989 = this.success[kiter988]; - output.writeI64(kiter988); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter989)); - for (let kiter990 in viter989) { - if (viter989.hasOwnProperty(kiter990)) { - let viter991 = viter989[kiter990]; - output.writeString(kiter990); - output.writeSetBegin(Thrift.Type.STRUCT, viter991.length); - for (let iter992 in viter991) { - if (viter991.hasOwnProperty(iter992)) { - iter992 = viter991[iter992]; - iter992.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCclTime_args = class { - constructor(args) { - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCclTime_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp3994 = input.readMapBegin(); - const _size993 = _rtmp3994.size || 0; - for (let _i995 = 0; _i995 < _size993; ++_i995) { - let key996 = null; - let val997 = null; - key996 = input.readI64(); - val997 = {}; - const _rtmp3999 = input.readMapBegin(); - const _size998 = _rtmp3999.size || 0; - for (let _i1000 = 0; _i1000 < _size998; ++_i1000) { - let key1001 = null; - let val1002 = null; - key1001 = input.readString(); - val1002 = []; - const _rtmp31004 = input.readSetBegin(); - const _size1003 = _rtmp31004.size || 0; - for (let _i1005 = 0; _i1005 < _size1003; ++_i1005) { - let elem1006 = null; - elem1006 = new data_ttypes.TObject(); - elem1006.read(input); - val1002.push(elem1006); - } - input.readSetEnd(); - val997[key1001] = val1002; - } - input.readMapEnd(); - this.success[key996] = val997; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1007 in this.success) { - if (this.success.hasOwnProperty(kiter1007)) { - let viter1008 = this.success[kiter1007]; - output.writeI64(kiter1007); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1008)); - for (let kiter1009 in viter1008) { - if (viter1008.hasOwnProperty(kiter1009)) { - let viter1010 = viter1008[kiter1009]; - output.writeString(kiter1009); - output.writeSetBegin(Thrift.Type.STRUCT, viter1010.length); - for (let iter1011 in viter1010) { - if (viter1010.hasOwnProperty(iter1011)) { - iter1011 = viter1010[iter1011]; - iter1011.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCclTimestr_args = class { - constructor(args) { - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCclTimestr_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31013 = input.readMapBegin(); - const _size1012 = _rtmp31013.size || 0; - for (let _i1014 = 0; _i1014 < _size1012; ++_i1014) { - let key1015 = null; - let val1016 = null; - key1015 = input.readI64(); - val1016 = {}; - const _rtmp31018 = input.readMapBegin(); - const _size1017 = _rtmp31018.size || 0; - for (let _i1019 = 0; _i1019 < _size1017; ++_i1019) { - let key1020 = null; - let val1021 = null; - key1020 = input.readString(); - val1021 = []; - const _rtmp31023 = input.readSetBegin(); - const _size1022 = _rtmp31023.size || 0; - for (let _i1024 = 0; _i1024 < _size1022; ++_i1024) { - let elem1025 = null; - elem1025 = new data_ttypes.TObject(); - elem1025.read(input); - val1021.push(elem1025); - } - input.readSetEnd(); - val1016[key1020] = val1021; - } - input.readMapEnd(); - this.success[key1015] = val1016; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1026 in this.success) { - if (this.success.hasOwnProperty(kiter1026)) { - let viter1027 = this.success[kiter1026]; - output.writeI64(kiter1026); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1027)); - for (let kiter1028 in viter1027) { - if (viter1027.hasOwnProperty(kiter1028)) { - let viter1029 = viter1027[kiter1028]; - output.writeString(kiter1028); - output.writeSetBegin(Thrift.Type.STRUCT, viter1029.length); - for (let iter1030 in viter1029) { - if (viter1029.hasOwnProperty(iter1030)) { - iter1030 = viter1029[iter1030]; - iter1030.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31032 = input.readMapBegin(); - const _size1031 = _rtmp31032.size || 0; - for (let _i1033 = 0; _i1033 < _size1031; ++_i1033) { - let key1034 = null; - let val1035 = null; - key1034 = input.readI64(); - val1035 = []; - const _rtmp31037 = input.readSetBegin(); - const _size1036 = _rtmp31037.size || 0; - for (let _i1038 = 0; _i1038 < _size1036; ++_i1038) { - let elem1039 = null; - elem1039 = new data_ttypes.TObject(); - elem1039.read(input); - val1035.push(elem1039); - } - input.readSetEnd(); - this.success[key1034] = val1035; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1040 in this.success) { - if (this.success.hasOwnProperty(kiter1040)) { - let viter1041 = this.success[kiter1040]; - output.writeI64(kiter1040); - output.writeSetBegin(Thrift.Type.STRUCT, viter1041.length); - for (let iter1042 in viter1041) { - if (viter1041.hasOwnProperty(iter1042)) { - iter1042 = viter1041[iter1042]; - iter1042.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31044 = input.readMapBegin(); - const _size1043 = _rtmp31044.size || 0; - for (let _i1045 = 0; _i1045 < _size1043; ++_i1045) { - let key1046 = null; - let val1047 = null; - key1046 = input.readI64(); - val1047 = []; - const _rtmp31049 = input.readSetBegin(); - const _size1048 = _rtmp31049.size || 0; - for (let _i1050 = 0; _i1050 < _size1048; ++_i1050) { - let elem1051 = null; - elem1051 = new data_ttypes.TObject(); - elem1051.read(input); - val1047.push(elem1051); - } - input.readSetEnd(); - this.success[key1046] = val1047; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1052 in this.success) { - if (this.success.hasOwnProperty(kiter1052)) { - let viter1053 = this.success[kiter1052]; - output.writeI64(kiter1052); - output.writeSetBegin(Thrift.Type.STRUCT, viter1053.length); - for (let iter1054 in viter1053) { - if (viter1053.hasOwnProperty(iter1054)) { - iter1054 = viter1053[iter1054]; - iter1054.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31056 = input.readMapBegin(); - const _size1055 = _rtmp31056.size || 0; - for (let _i1057 = 0; _i1057 < _size1055; ++_i1057) { - let key1058 = null; - let val1059 = null; - key1058 = input.readI64(); - val1059 = []; - const _rtmp31061 = input.readSetBegin(); - const _size1060 = _rtmp31061.size || 0; - for (let _i1062 = 0; _i1062 < _size1060; ++_i1062) { - let elem1063 = null; - elem1063 = new data_ttypes.TObject(); - elem1063.read(input); - val1059.push(elem1063); - } - input.readSetEnd(); - this.success[key1058] = val1059; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1064 in this.success) { - if (this.success.hasOwnProperty(kiter1064)) { - let viter1065 = this.success[kiter1064]; - output.writeI64(kiter1064); - output.writeSetBegin(Thrift.Type.STRUCT, viter1065.length); - for (let iter1066 in viter1065) { - if (viter1065.hasOwnProperty(iter1066)) { - iter1066 = viter1065[iter1066]; - iter1066.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31068 = input.readMapBegin(); - const _size1067 = _rtmp31068.size || 0; - for (let _i1069 = 0; _i1069 < _size1067; ++_i1069) { - let key1070 = null; - let val1071 = null; - key1070 = input.readI64(); - val1071 = []; - const _rtmp31073 = input.readSetBegin(); - const _size1072 = _rtmp31073.size || 0; - for (let _i1074 = 0; _i1074 < _size1072; ++_i1074) { - let elem1075 = null; - elem1075 = new data_ttypes.TObject(); - elem1075.read(input); - val1071.push(elem1075); - } - input.readSetEnd(); - this.success[key1070] = val1071; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1076 in this.success) { - if (this.success.hasOwnProperty(kiter1076)) { - let viter1077 = this.success[kiter1076]; - output.writeI64(kiter1076); - output.writeSetBegin(Thrift.Type.STRUCT, viter1077.length); - for (let iter1078 in viter1077) { - if (viter1077.hasOwnProperty(iter1078)) { - iter1078 = viter1077[iter1078]; - iter1078.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31080 = input.readMapBegin(); - const _size1079 = _rtmp31080.size || 0; - for (let _i1081 = 0; _i1081 < _size1079; ++_i1081) { - let key1082 = null; - let val1083 = null; - key1082 = input.readI64(); - val1083 = []; - const _rtmp31085 = input.readSetBegin(); - const _size1084 = _rtmp31085.size || 0; - for (let _i1086 = 0; _i1086 < _size1084; ++_i1086) { - let elem1087 = null; - elem1087 = new data_ttypes.TObject(); - elem1087.read(input); - val1083.push(elem1087); - } - input.readSetEnd(); - this.success[key1082] = val1083; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1088 in this.success) { - if (this.success.hasOwnProperty(kiter1088)) { - let viter1089 = this.success[kiter1088]; - output.writeI64(kiter1088); - output.writeSetBegin(Thrift.Type.STRUCT, viter1089.length); - for (let iter1090 in viter1089) { - if (viter1089.hasOwnProperty(iter1090)) { - iter1090 = viter1089[iter1090]; - iter1090.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31092 = input.readMapBegin(); - const _size1091 = _rtmp31092.size || 0; - for (let _i1093 = 0; _i1093 < _size1091; ++_i1093) { - let key1094 = null; - let val1095 = null; - key1094 = input.readI64(); - val1095 = []; - const _rtmp31097 = input.readSetBegin(); - const _size1096 = _rtmp31097.size || 0; - for (let _i1098 = 0; _i1098 < _size1096; ++_i1098) { - let elem1099 = null; - elem1099 = new data_ttypes.TObject(); - elem1099.read(input); - val1095.push(elem1099); - } - input.readSetEnd(); - this.success[key1094] = val1095; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1100 in this.success) { - if (this.success.hasOwnProperty(kiter1100)) { - let viter1101 = this.success[kiter1100]; - output.writeI64(kiter1100); - output.writeSetBegin(Thrift.Type.STRUCT, viter1101.length); - for (let iter1102 in viter1101) { - if (viter1101.hasOwnProperty(iter1102)) { - iter1102 = viter1101[iter1102]; - iter1102.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCriteria_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31104 = input.readListBegin(); - const _size1103 = _rtmp31104.size || 0; - for (let _i1105 = 0; _i1105 < _size1103; ++_i1105) { - let elem1106 = null; - elem1106 = input.readString(); - this.keys.push(elem1106); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCriteria_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1107 in this.keys) { - if (this.keys.hasOwnProperty(iter1107)) { - iter1107 = this.keys[iter1107]; - output.writeString(iter1107); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31109 = input.readMapBegin(); - const _size1108 = _rtmp31109.size || 0; - for (let _i1110 = 0; _i1110 < _size1108; ++_i1110) { - let key1111 = null; - let val1112 = null; - key1111 = input.readI64(); - val1112 = {}; - const _rtmp31114 = input.readMapBegin(); - const _size1113 = _rtmp31114.size || 0; - for (let _i1115 = 0; _i1115 < _size1113; ++_i1115) { - let key1116 = null; - let val1117 = null; - key1116 = input.readString(); - val1117 = []; - const _rtmp31119 = input.readSetBegin(); - const _size1118 = _rtmp31119.size || 0; - for (let _i1120 = 0; _i1120 < _size1118; ++_i1120) { - let elem1121 = null; - elem1121 = new data_ttypes.TObject(); - elem1121.read(input); - val1117.push(elem1121); - } - input.readSetEnd(); - val1112[key1116] = val1117; - } - input.readMapEnd(); - this.success[key1111] = val1112; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1122 in this.success) { - if (this.success.hasOwnProperty(kiter1122)) { - let viter1123 = this.success[kiter1122]; - output.writeI64(kiter1122); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1123)); - for (let kiter1124 in viter1123) { - if (viter1123.hasOwnProperty(kiter1124)) { - let viter1125 = viter1123[kiter1124]; - output.writeString(kiter1124); - output.writeSetBegin(Thrift.Type.STRUCT, viter1125.length); - for (let iter1126 in viter1125) { - if (viter1125.hasOwnProperty(iter1126)) { - iter1126 = viter1125[iter1126]; - iter1126.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCcl_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31128 = input.readListBegin(); - const _size1127 = _rtmp31128.size || 0; - for (let _i1129 = 0; _i1129 < _size1127; ++_i1129) { - let elem1130 = null; - elem1130 = input.readString(); - this.keys.push(elem1130); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCcl_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1131 in this.keys) { - if (this.keys.hasOwnProperty(iter1131)) { - iter1131 = this.keys[iter1131]; - output.writeString(iter1131); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31133 = input.readMapBegin(); - const _size1132 = _rtmp31133.size || 0; - for (let _i1134 = 0; _i1134 < _size1132; ++_i1134) { - let key1135 = null; - let val1136 = null; - key1135 = input.readI64(); - val1136 = {}; - const _rtmp31138 = input.readMapBegin(); - const _size1137 = _rtmp31138.size || 0; - for (let _i1139 = 0; _i1139 < _size1137; ++_i1139) { - let key1140 = null; - let val1141 = null; - key1140 = input.readString(); - val1141 = []; - const _rtmp31143 = input.readSetBegin(); - const _size1142 = _rtmp31143.size || 0; - for (let _i1144 = 0; _i1144 < _size1142; ++_i1144) { - let elem1145 = null; - elem1145 = new data_ttypes.TObject(); - elem1145.read(input); - val1141.push(elem1145); - } - input.readSetEnd(); - val1136[key1140] = val1141; - } - input.readMapEnd(); - this.success[key1135] = val1136; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1146 in this.success) { - if (this.success.hasOwnProperty(kiter1146)) { - let viter1147 = this.success[kiter1146]; - output.writeI64(kiter1146); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1147)); - for (let kiter1148 in viter1147) { - if (viter1147.hasOwnProperty(kiter1148)) { - let viter1149 = viter1147[kiter1148]; - output.writeString(kiter1148); - output.writeSetBegin(Thrift.Type.STRUCT, viter1149.length); - for (let iter1150 in viter1149) { - if (viter1149.hasOwnProperty(iter1150)) { - iter1150 = viter1149[iter1150]; - iter1150.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCriteriaTime_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31152 = input.readListBegin(); - const _size1151 = _rtmp31152.size || 0; - for (let _i1153 = 0; _i1153 < _size1151; ++_i1153) { - let elem1154 = null; - elem1154 = input.readString(); - this.keys.push(elem1154); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCriteriaTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1155 in this.keys) { - if (this.keys.hasOwnProperty(iter1155)) { - iter1155 = this.keys[iter1155]; - output.writeString(iter1155); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31157 = input.readMapBegin(); - const _size1156 = _rtmp31157.size || 0; - for (let _i1158 = 0; _i1158 < _size1156; ++_i1158) { - let key1159 = null; - let val1160 = null; - key1159 = input.readI64(); - val1160 = {}; - const _rtmp31162 = input.readMapBegin(); - const _size1161 = _rtmp31162.size || 0; - for (let _i1163 = 0; _i1163 < _size1161; ++_i1163) { - let key1164 = null; - let val1165 = null; - key1164 = input.readString(); - val1165 = []; - const _rtmp31167 = input.readSetBegin(); - const _size1166 = _rtmp31167.size || 0; - for (let _i1168 = 0; _i1168 < _size1166; ++_i1168) { - let elem1169 = null; - elem1169 = new data_ttypes.TObject(); - elem1169.read(input); - val1165.push(elem1169); - } - input.readSetEnd(); - val1160[key1164] = val1165; - } - input.readMapEnd(); - this.success[key1159] = val1160; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1170 in this.success) { - if (this.success.hasOwnProperty(kiter1170)) { - let viter1171 = this.success[kiter1170]; - output.writeI64(kiter1170); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1171)); - for (let kiter1172 in viter1171) { - if (viter1171.hasOwnProperty(kiter1172)) { - let viter1173 = viter1171[kiter1172]; - output.writeString(kiter1172); - output.writeSetBegin(Thrift.Type.STRUCT, viter1173.length); - for (let iter1174 in viter1173) { - if (viter1173.hasOwnProperty(iter1174)) { - iter1174 = viter1173[iter1174]; - iter1174.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCriteriaTimestr_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31176 = input.readListBegin(); - const _size1175 = _rtmp31176.size || 0; - for (let _i1177 = 0; _i1177 < _size1175; ++_i1177) { - let elem1178 = null; - elem1178 = input.readString(); - this.keys.push(elem1178); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCriteriaTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1179 in this.keys) { - if (this.keys.hasOwnProperty(iter1179)) { - iter1179 = this.keys[iter1179]; - output.writeString(iter1179); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31181 = input.readMapBegin(); - const _size1180 = _rtmp31181.size || 0; - for (let _i1182 = 0; _i1182 < _size1180; ++_i1182) { - let key1183 = null; - let val1184 = null; - key1183 = input.readI64(); - val1184 = {}; - const _rtmp31186 = input.readMapBegin(); - const _size1185 = _rtmp31186.size || 0; - for (let _i1187 = 0; _i1187 < _size1185; ++_i1187) { - let key1188 = null; - let val1189 = null; - key1188 = input.readString(); - val1189 = []; - const _rtmp31191 = input.readSetBegin(); - const _size1190 = _rtmp31191.size || 0; - for (let _i1192 = 0; _i1192 < _size1190; ++_i1192) { - let elem1193 = null; - elem1193 = new data_ttypes.TObject(); - elem1193.read(input); - val1189.push(elem1193); - } - input.readSetEnd(); - val1184[key1188] = val1189; - } - input.readMapEnd(); - this.success[key1183] = val1184; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1194 in this.success) { - if (this.success.hasOwnProperty(kiter1194)) { - let viter1195 = this.success[kiter1194]; - output.writeI64(kiter1194); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1195)); - for (let kiter1196 in viter1195) { - if (viter1195.hasOwnProperty(kiter1196)) { - let viter1197 = viter1195[kiter1196]; - output.writeString(kiter1196); - output.writeSetBegin(Thrift.Type.STRUCT, viter1197.length); - for (let iter1198 in viter1197) { - if (viter1197.hasOwnProperty(iter1198)) { - iter1198 = viter1197[iter1198]; - iter1198.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCclTime_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31200 = input.readListBegin(); - const _size1199 = _rtmp31200.size || 0; - for (let _i1201 = 0; _i1201 < _size1199; ++_i1201) { - let elem1202 = null; - elem1202 = input.readString(); - this.keys.push(elem1202); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCclTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1203 in this.keys) { - if (this.keys.hasOwnProperty(iter1203)) { - iter1203 = this.keys[iter1203]; - output.writeString(iter1203); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31205 = input.readMapBegin(); - const _size1204 = _rtmp31205.size || 0; - for (let _i1206 = 0; _i1206 < _size1204; ++_i1206) { - let key1207 = null; - let val1208 = null; - key1207 = input.readI64(); - val1208 = {}; - const _rtmp31210 = input.readMapBegin(); - const _size1209 = _rtmp31210.size || 0; - for (let _i1211 = 0; _i1211 < _size1209; ++_i1211) { - let key1212 = null; - let val1213 = null; - key1212 = input.readString(); - val1213 = []; - const _rtmp31215 = input.readSetBegin(); - const _size1214 = _rtmp31215.size || 0; - for (let _i1216 = 0; _i1216 < _size1214; ++_i1216) { - let elem1217 = null; - elem1217 = new data_ttypes.TObject(); - elem1217.read(input); - val1213.push(elem1217); - } - input.readSetEnd(); - val1208[key1212] = val1213; - } - input.readMapEnd(); - this.success[key1207] = val1208; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1218 in this.success) { - if (this.success.hasOwnProperty(kiter1218)) { - let viter1219 = this.success[kiter1218]; - output.writeI64(kiter1218); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1219)); - for (let kiter1220 in viter1219) { - if (viter1219.hasOwnProperty(kiter1220)) { - let viter1221 = viter1219[kiter1220]; - output.writeString(kiter1220); - output.writeSetBegin(Thrift.Type.STRUCT, viter1221.length); - for (let iter1222 in viter1221) { - if (viter1221.hasOwnProperty(iter1222)) { - iter1222 = viter1221[iter1222]; - iter1222.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCclTimestr_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31224 = input.readListBegin(); - const _size1223 = _rtmp31224.size || 0; - for (let _i1225 = 0; _i1225 < _size1223; ++_i1225) { - let elem1226 = null; - elem1226 = input.readString(); - this.keys.push(elem1226); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCclTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1227 in this.keys) { - if (this.keys.hasOwnProperty(iter1227)) { - iter1227 = this.keys[iter1227]; - output.writeString(iter1227); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_selectKeysCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31229 = input.readMapBegin(); - const _size1228 = _rtmp31229.size || 0; - for (let _i1230 = 0; _i1230 < _size1228; ++_i1230) { - let key1231 = null; - let val1232 = null; - key1231 = input.readI64(); - val1232 = {}; - const _rtmp31234 = input.readMapBegin(); - const _size1233 = _rtmp31234.size || 0; - for (let _i1235 = 0; _i1235 < _size1233; ++_i1235) { - let key1236 = null; - let val1237 = null; - key1236 = input.readString(); - val1237 = []; - const _rtmp31239 = input.readSetBegin(); - const _size1238 = _rtmp31239.size || 0; - for (let _i1240 = 0; _i1240 < _size1238; ++_i1240) { - let elem1241 = null; - elem1241 = new data_ttypes.TObject(); - elem1241.read(input); - val1237.push(elem1241); - } - input.readSetEnd(); - val1232[key1236] = val1237; - } - input.readMapEnd(); - this.success[key1231] = val1232; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_selectKeysCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1242 in this.success) { - if (this.success.hasOwnProperty(kiter1242)) { - let viter1243 = this.success[kiter1242]; - output.writeI64(kiter1242); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1243)); - for (let kiter1244 in viter1243) { - if (viter1243.hasOwnProperty(kiter1244)) { - let viter1245 = viter1243[kiter1244]; - output.writeString(kiter1244); - output.writeSetBegin(Thrift.Type.STRUCT, viter1245.length); - for (let iter1246 in viter1245) { - if (viter1245.hasOwnProperty(iter1246)) { - iter1246 = viter1245[iter1246]; - iter1246.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecord_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31248 = input.readListBegin(); - const _size1247 = _rtmp31248.size || 0; - for (let _i1249 = 0; _i1249 < _size1247; ++_i1249) { - let elem1250 = null; - elem1250 = input.readString(); - this.keys.push(elem1250); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecord_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1251 in this.keys) { - if (this.keys.hasOwnProperty(iter1251)) { - iter1251 = this.keys[iter1251]; - output.writeString(iter1251); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31253 = input.readMapBegin(); - const _size1252 = _rtmp31253.size || 0; - for (let _i1254 = 0; _i1254 < _size1252; ++_i1254) { - let key1255 = null; - let val1256 = null; - key1255 = input.readString(); - val1256 = new data_ttypes.TObject(); - val1256.read(input); - this.success[key1255] = val1256; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1257 in this.success) { - if (this.success.hasOwnProperty(kiter1257)) { - let viter1258 = this.success[kiter1257]; - output.writeString(kiter1257); - viter1258.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordTime_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31260 = input.readListBegin(); - const _size1259 = _rtmp31260.size || 0; - for (let _i1261 = 0; _i1261 < _size1259; ++_i1261) { - let elem1262 = null; - elem1262 = input.readString(); - this.keys.push(elem1262); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1263 in this.keys) { - if (this.keys.hasOwnProperty(iter1263)) { - iter1263 = this.keys[iter1263]; - output.writeString(iter1263); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31265 = input.readMapBegin(); - const _size1264 = _rtmp31265.size || 0; - for (let _i1266 = 0; _i1266 < _size1264; ++_i1266) { - let key1267 = null; - let val1268 = null; - key1267 = input.readString(); - val1268 = new data_ttypes.TObject(); - val1268.read(input); - this.success[key1267] = val1268; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1269 in this.success) { - if (this.success.hasOwnProperty(kiter1269)) { - let viter1270 = this.success[kiter1269]; - output.writeString(kiter1269); - viter1270.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordTimestr_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31272 = input.readListBegin(); - const _size1271 = _rtmp31272.size || 0; - for (let _i1273 = 0; _i1273 < _size1271; ++_i1273) { - let elem1274 = null; - elem1274 = input.readString(); - this.keys.push(elem1274); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1275 in this.keys) { - if (this.keys.hasOwnProperty(iter1275)) { - iter1275 = this.keys[iter1275]; - output.writeString(iter1275); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31277 = input.readMapBegin(); - const _size1276 = _rtmp31277.size || 0; - for (let _i1278 = 0; _i1278 < _size1276; ++_i1278) { - let key1279 = null; - let val1280 = null; - key1279 = input.readString(); - val1280 = new data_ttypes.TObject(); - val1280.read(input); - this.success[key1279] = val1280; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1281 in this.success) { - if (this.success.hasOwnProperty(kiter1281)) { - let viter1282 = this.success[kiter1281]; - output.writeString(kiter1281); - viter1282.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecords_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31284 = input.readListBegin(); - const _size1283 = _rtmp31284.size || 0; - for (let _i1285 = 0; _i1285 < _size1283; ++_i1285) { - let elem1286 = null; - elem1286 = input.readString(); - this.keys.push(elem1286); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31288 = input.readListBegin(); - const _size1287 = _rtmp31288.size || 0; - for (let _i1289 = 0; _i1289 < _size1287; ++_i1289) { - let elem1290 = null; - elem1290 = input.readI64(); - this.records.push(elem1290); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecords_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1291 in this.keys) { - if (this.keys.hasOwnProperty(iter1291)) { - iter1291 = this.keys[iter1291]; - output.writeString(iter1291); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1292 in this.records) { - if (this.records.hasOwnProperty(iter1292)) { - iter1292 = this.records[iter1292]; - output.writeI64(iter1292); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31294 = input.readMapBegin(); - const _size1293 = _rtmp31294.size || 0; - for (let _i1295 = 0; _i1295 < _size1293; ++_i1295) { - let key1296 = null; - let val1297 = null; - key1296 = input.readI64(); - val1297 = {}; - const _rtmp31299 = input.readMapBegin(); - const _size1298 = _rtmp31299.size || 0; - for (let _i1300 = 0; _i1300 < _size1298; ++_i1300) { - let key1301 = null; - let val1302 = null; - key1301 = input.readString(); - val1302 = new data_ttypes.TObject(); - val1302.read(input); - val1297[key1301] = val1302; - } - input.readMapEnd(); - this.success[key1296] = val1297; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1303 in this.success) { - if (this.success.hasOwnProperty(kiter1303)) { - let viter1304 = this.success[kiter1303]; - output.writeI64(kiter1303); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1304)); - for (let kiter1305 in viter1304) { - if (viter1304.hasOwnProperty(kiter1305)) { - let viter1306 = viter1304[kiter1305]; - output.writeString(kiter1305); - viter1306.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31308 = input.readListBegin(); - const _size1307 = _rtmp31308.size || 0; - for (let _i1309 = 0; _i1309 < _size1307; ++_i1309) { - let elem1310 = null; - elem1310 = input.readI64(); - this.records.push(elem1310); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1311 in this.records) { - if (this.records.hasOwnProperty(iter1311)) { - iter1311 = this.records[iter1311]; - output.writeI64(iter1311); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31313 = input.readMapBegin(); - const _size1312 = _rtmp31313.size || 0; - for (let _i1314 = 0; _i1314 < _size1312; ++_i1314) { - let key1315 = null; - let val1316 = null; - key1315 = input.readI64(); - val1316 = new data_ttypes.TObject(); - val1316.read(input); - this.success[key1315] = val1316; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1317 in this.success) { - if (this.success.hasOwnProperty(kiter1317)) { - let viter1318 = this.success[kiter1317]; - output.writeI64(kiter1317); - viter1318.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31320 = input.readListBegin(); - const _size1319 = _rtmp31320.size || 0; - for (let _i1321 = 0; _i1321 < _size1319; ++_i1321) { - let elem1322 = null; - elem1322 = input.readI64(); - this.records.push(elem1322); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1323 in this.records) { - if (this.records.hasOwnProperty(iter1323)) { - iter1323 = this.records[iter1323]; - output.writeI64(iter1323); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31325 = input.readMapBegin(); - const _size1324 = _rtmp31325.size || 0; - for (let _i1326 = 0; _i1326 < _size1324; ++_i1326) { - let key1327 = null; - let val1328 = null; - key1327 = input.readI64(); - val1328 = new data_ttypes.TObject(); - val1328.read(input); - this.success[key1327] = val1328; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1329 in this.success) { - if (this.success.hasOwnProperty(kiter1329)) { - let viter1330 = this.success[kiter1329]; - output.writeI64(kiter1329); - viter1330.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31332 = input.readListBegin(); - const _size1331 = _rtmp31332.size || 0; - for (let _i1333 = 0; _i1333 < _size1331; ++_i1333) { - let elem1334 = null; - elem1334 = input.readI64(); - this.records.push(elem1334); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1335 in this.records) { - if (this.records.hasOwnProperty(iter1335)) { - iter1335 = this.records[iter1335]; - output.writeI64(iter1335); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31337 = input.readMapBegin(); - const _size1336 = _rtmp31337.size || 0; - for (let _i1338 = 0; _i1338 < _size1336; ++_i1338) { - let key1339 = null; - let val1340 = null; - key1339 = input.readI64(); - val1340 = new data_ttypes.TObject(); - val1340.read(input); - this.success[key1339] = val1340; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1341 in this.success) { - if (this.success.hasOwnProperty(kiter1341)) { - let viter1342 = this.success[kiter1341]; - output.writeI64(kiter1341); - viter1342.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordsTime_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31344 = input.readListBegin(); - const _size1343 = _rtmp31344.size || 0; - for (let _i1345 = 0; _i1345 < _size1343; ++_i1345) { - let elem1346 = null; - elem1346 = input.readString(); - this.keys.push(elem1346); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31348 = input.readListBegin(); - const _size1347 = _rtmp31348.size || 0; - for (let _i1349 = 0; _i1349 < _size1347; ++_i1349) { - let elem1350 = null; - elem1350 = input.readI64(); - this.records.push(elem1350); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordsTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1351 in this.keys) { - if (this.keys.hasOwnProperty(iter1351)) { - iter1351 = this.keys[iter1351]; - output.writeString(iter1351); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1352 in this.records) { - if (this.records.hasOwnProperty(iter1352)) { - iter1352 = this.records[iter1352]; - output.writeI64(iter1352); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31354 = input.readMapBegin(); - const _size1353 = _rtmp31354.size || 0; - for (let _i1355 = 0; _i1355 < _size1353; ++_i1355) { - let key1356 = null; - let val1357 = null; - key1356 = input.readI64(); - val1357 = {}; - const _rtmp31359 = input.readMapBegin(); - const _size1358 = _rtmp31359.size || 0; - for (let _i1360 = 0; _i1360 < _size1358; ++_i1360) { - let key1361 = null; - let val1362 = null; - key1361 = input.readString(); - val1362 = new data_ttypes.TObject(); - val1362.read(input); - val1357[key1361] = val1362; - } - input.readMapEnd(); - this.success[key1356] = val1357; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1363 in this.success) { - if (this.success.hasOwnProperty(kiter1363)) { - let viter1364 = this.success[kiter1363]; - output.writeI64(kiter1363); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1364)); - for (let kiter1365 in viter1364) { - if (viter1364.hasOwnProperty(kiter1365)) { - let viter1366 = viter1364[kiter1365]; - output.writeString(kiter1365); - viter1366.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordsTimestr_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31368 = input.readListBegin(); - const _size1367 = _rtmp31368.size || 0; - for (let _i1369 = 0; _i1369 < _size1367; ++_i1369) { - let elem1370 = null; - elem1370 = input.readString(); - this.keys.push(elem1370); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31372 = input.readListBegin(); - const _size1371 = _rtmp31372.size || 0; - for (let _i1373 = 0; _i1373 < _size1371; ++_i1373) { - let elem1374 = null; - elem1374 = input.readI64(); - this.records.push(elem1374); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordsTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1375 in this.keys) { - if (this.keys.hasOwnProperty(iter1375)) { - iter1375 = this.keys[iter1375]; - output.writeString(iter1375); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1376 in this.records) { - if (this.records.hasOwnProperty(iter1376)) { - iter1376 = this.records[iter1376]; - output.writeI64(iter1376); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31378 = input.readMapBegin(); - const _size1377 = _rtmp31378.size || 0; - for (let _i1379 = 0; _i1379 < _size1377; ++_i1379) { - let key1380 = null; - let val1381 = null; - key1380 = input.readI64(); - val1381 = {}; - const _rtmp31383 = input.readMapBegin(); - const _size1382 = _rtmp31383.size || 0; - for (let _i1384 = 0; _i1384 < _size1382; ++_i1384) { - let key1385 = null; - let val1386 = null; - key1385 = input.readString(); - val1386 = new data_ttypes.TObject(); - val1386.read(input); - val1381[key1385] = val1386; - } - input.readMapEnd(); - this.success[key1380] = val1381; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1387 in this.success) { - if (this.success.hasOwnProperty(kiter1387)) { - let viter1388 = this.success[kiter1387]; - output.writeI64(kiter1387); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1388)); - for (let kiter1389 in viter1388) { - if (viter1388.hasOwnProperty(kiter1389)) { - let viter1390 = viter1388[kiter1389]; - output.writeString(kiter1389); - viter1390.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31392 = input.readMapBegin(); - const _size1391 = _rtmp31392.size || 0; - for (let _i1393 = 0; _i1393 < _size1391; ++_i1393) { - let key1394 = null; - let val1395 = null; - key1394 = input.readI64(); - val1395 = new data_ttypes.TObject(); - val1395.read(input); - this.success[key1394] = val1395; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1396 in this.success) { - if (this.success.hasOwnProperty(kiter1396)) { - let viter1397 = this.success[kiter1396]; - output.writeI64(kiter1396); - viter1397.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCriteria_args = class { - constructor(args) { - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCriteria_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31399 = input.readMapBegin(); - const _size1398 = _rtmp31399.size || 0; - for (let _i1400 = 0; _i1400 < _size1398; ++_i1400) { - let key1401 = null; - let val1402 = null; - key1401 = input.readI64(); - val1402 = {}; - const _rtmp31404 = input.readMapBegin(); - const _size1403 = _rtmp31404.size || 0; - for (let _i1405 = 0; _i1405 < _size1403; ++_i1405) { - let key1406 = null; - let val1407 = null; - key1406 = input.readString(); - val1407 = new data_ttypes.TObject(); - val1407.read(input); - val1402[key1406] = val1407; - } - input.readMapEnd(); - this.success[key1401] = val1402; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1408 in this.success) { - if (this.success.hasOwnProperty(kiter1408)) { - let viter1409 = this.success[kiter1408]; - output.writeI64(kiter1408); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1409)); - for (let kiter1410 in viter1409) { - if (viter1409.hasOwnProperty(kiter1410)) { - let viter1411 = viter1409[kiter1410]; - output.writeString(kiter1410); - viter1411.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCcl_args = class { - constructor(args) { - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCcl_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31413 = input.readMapBegin(); - const _size1412 = _rtmp31413.size || 0; - for (let _i1414 = 0; _i1414 < _size1412; ++_i1414) { - let key1415 = null; - let val1416 = null; - key1415 = input.readI64(); - val1416 = {}; - const _rtmp31418 = input.readMapBegin(); - const _size1417 = _rtmp31418.size || 0; - for (let _i1419 = 0; _i1419 < _size1417; ++_i1419) { - let key1420 = null; - let val1421 = null; - key1420 = input.readString(); - val1421 = new data_ttypes.TObject(); - val1421.read(input); - val1416[key1420] = val1421; - } - input.readMapEnd(); - this.success[key1415] = val1416; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1422 in this.success) { - if (this.success.hasOwnProperty(kiter1422)) { - let viter1423 = this.success[kiter1422]; - output.writeI64(kiter1422); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1423)); - for (let kiter1424 in viter1423) { - if (viter1423.hasOwnProperty(kiter1424)) { - let viter1425 = viter1423[kiter1424]; - output.writeString(kiter1424); - viter1425.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCriteriaTime_args = class { - constructor(args) { - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCriteriaTime_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31427 = input.readMapBegin(); - const _size1426 = _rtmp31427.size || 0; - for (let _i1428 = 0; _i1428 < _size1426; ++_i1428) { - let key1429 = null; - let val1430 = null; - key1429 = input.readI64(); - val1430 = {}; - const _rtmp31432 = input.readMapBegin(); - const _size1431 = _rtmp31432.size || 0; - for (let _i1433 = 0; _i1433 < _size1431; ++_i1433) { - let key1434 = null; - let val1435 = null; - key1434 = input.readString(); - val1435 = new data_ttypes.TObject(); - val1435.read(input); - val1430[key1434] = val1435; - } - input.readMapEnd(); - this.success[key1429] = val1430; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1436 in this.success) { - if (this.success.hasOwnProperty(kiter1436)) { - let viter1437 = this.success[kiter1436]; - output.writeI64(kiter1436); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1437)); - for (let kiter1438 in viter1437) { - if (viter1437.hasOwnProperty(kiter1438)) { - let viter1439 = viter1437[kiter1438]; - output.writeString(kiter1438); - viter1439.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCriteriaTimestr_args = class { - constructor(args) { - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCriteriaTimestr_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31441 = input.readMapBegin(); - const _size1440 = _rtmp31441.size || 0; - for (let _i1442 = 0; _i1442 < _size1440; ++_i1442) { - let key1443 = null; - let val1444 = null; - key1443 = input.readI64(); - val1444 = {}; - const _rtmp31446 = input.readMapBegin(); - const _size1445 = _rtmp31446.size || 0; - for (let _i1447 = 0; _i1447 < _size1445; ++_i1447) { - let key1448 = null; - let val1449 = null; - key1448 = input.readString(); - val1449 = new data_ttypes.TObject(); - val1449.read(input); - val1444[key1448] = val1449; - } - input.readMapEnd(); - this.success[key1443] = val1444; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1450 in this.success) { - if (this.success.hasOwnProperty(kiter1450)) { - let viter1451 = this.success[kiter1450]; - output.writeI64(kiter1450); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1451)); - for (let kiter1452 in viter1451) { - if (viter1451.hasOwnProperty(kiter1452)) { - let viter1453 = viter1451[kiter1452]; - output.writeString(kiter1452); - viter1453.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCclTime_args = class { - constructor(args) { - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCclTime_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31455 = input.readMapBegin(); - const _size1454 = _rtmp31455.size || 0; - for (let _i1456 = 0; _i1456 < _size1454; ++_i1456) { - let key1457 = null; - let val1458 = null; - key1457 = input.readI64(); - val1458 = {}; - const _rtmp31460 = input.readMapBegin(); - const _size1459 = _rtmp31460.size || 0; - for (let _i1461 = 0; _i1461 < _size1459; ++_i1461) { - let key1462 = null; - let val1463 = null; - key1462 = input.readString(); - val1463 = new data_ttypes.TObject(); - val1463.read(input); - val1458[key1462] = val1463; - } - input.readMapEnd(); - this.success[key1457] = val1458; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1464 in this.success) { - if (this.success.hasOwnProperty(kiter1464)) { - let viter1465 = this.success[kiter1464]; - output.writeI64(kiter1464); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1465)); - for (let kiter1466 in viter1465) { - if (viter1465.hasOwnProperty(kiter1466)) { - let viter1467 = viter1465[kiter1466]; - output.writeString(kiter1466); - viter1467.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCclTimestr_args = class { - constructor(args) { - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCclTimestr_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31469 = input.readMapBegin(); - const _size1468 = _rtmp31469.size || 0; - for (let _i1470 = 0; _i1470 < _size1468; ++_i1470) { - let key1471 = null; - let val1472 = null; - key1471 = input.readI64(); - val1472 = {}; - const _rtmp31474 = input.readMapBegin(); - const _size1473 = _rtmp31474.size || 0; - for (let _i1475 = 0; _i1475 < _size1473; ++_i1475) { - let key1476 = null; - let val1477 = null; - key1476 = input.readString(); - val1477 = new data_ttypes.TObject(); - val1477.read(input); - val1472[key1476] = val1477; - } - input.readMapEnd(); - this.success[key1471] = val1472; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1478 in this.success) { - if (this.success.hasOwnProperty(kiter1478)) { - let viter1479 = this.success[kiter1478]; - output.writeI64(kiter1478); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1479)); - for (let kiter1480 in viter1479) { - if (viter1479.hasOwnProperty(kiter1480)) { - let viter1481 = viter1479[kiter1480]; - output.writeString(kiter1480); - viter1481.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31483 = input.readMapBegin(); - const _size1482 = _rtmp31483.size || 0; - for (let _i1484 = 0; _i1484 < _size1482; ++_i1484) { - let key1485 = null; - let val1486 = null; - key1485 = input.readI64(); - val1486 = new data_ttypes.TObject(); - val1486.read(input); - this.success[key1485] = val1486; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1487 in this.success) { - if (this.success.hasOwnProperty(kiter1487)) { - let viter1488 = this.success[kiter1487]; - output.writeI64(kiter1487); - viter1488.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31490 = input.readMapBegin(); - const _size1489 = _rtmp31490.size || 0; - for (let _i1491 = 0; _i1491 < _size1489; ++_i1491) { - let key1492 = null; - let val1493 = null; - key1492 = input.readI64(); - val1493 = new data_ttypes.TObject(); - val1493.read(input); - this.success[key1492] = val1493; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1494 in this.success) { - if (this.success.hasOwnProperty(kiter1494)) { - let viter1495 = this.success[kiter1494]; - output.writeI64(kiter1494); - viter1495.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31497 = input.readMapBegin(); - const _size1496 = _rtmp31497.size || 0; - for (let _i1498 = 0; _i1498 < _size1496; ++_i1498) { - let key1499 = null; - let val1500 = null; - key1499 = input.readI64(); - val1500 = new data_ttypes.TObject(); - val1500.read(input); - this.success[key1499] = val1500; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1501 in this.success) { - if (this.success.hasOwnProperty(kiter1501)) { - let viter1502 = this.success[kiter1501]; - output.writeI64(kiter1501); - viter1502.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31504 = input.readMapBegin(); - const _size1503 = _rtmp31504.size || 0; - for (let _i1505 = 0; _i1505 < _size1503; ++_i1505) { - let key1506 = null; - let val1507 = null; - key1506 = input.readI64(); - val1507 = new data_ttypes.TObject(); - val1507.read(input); - this.success[key1506] = val1507; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1508 in this.success) { - if (this.success.hasOwnProperty(kiter1508)) { - let viter1509 = this.success[kiter1508]; - output.writeI64(kiter1508); - viter1509.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31511 = input.readMapBegin(); - const _size1510 = _rtmp31511.size || 0; - for (let _i1512 = 0; _i1512 < _size1510; ++_i1512) { - let key1513 = null; - let val1514 = null; - key1513 = input.readI64(); - val1514 = new data_ttypes.TObject(); - val1514.read(input); - this.success[key1513] = val1514; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.STRUCT, Thrift.objectLength(this.success)); - for (let kiter1515 in this.success) { - if (this.success.hasOwnProperty(kiter1515)) { - let viter1516 = this.success[kiter1515]; - output.writeI64(kiter1515); - viter1516.write(output); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCriteria_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31518 = input.readListBegin(); - const _size1517 = _rtmp31518.size || 0; - for (let _i1519 = 0; _i1519 < _size1517; ++_i1519) { - let elem1520 = null; - elem1520 = input.readString(); - this.keys.push(elem1520); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCriteria_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1521 in this.keys) { - if (this.keys.hasOwnProperty(iter1521)) { - iter1521 = this.keys[iter1521]; - output.writeString(iter1521); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31523 = input.readMapBegin(); - const _size1522 = _rtmp31523.size || 0; - for (let _i1524 = 0; _i1524 < _size1522; ++_i1524) { - let key1525 = null; - let val1526 = null; - key1525 = input.readI64(); - val1526 = {}; - const _rtmp31528 = input.readMapBegin(); - const _size1527 = _rtmp31528.size || 0; - for (let _i1529 = 0; _i1529 < _size1527; ++_i1529) { - let key1530 = null; - let val1531 = null; - key1530 = input.readString(); - val1531 = new data_ttypes.TObject(); - val1531.read(input); - val1526[key1530] = val1531; - } - input.readMapEnd(); - this.success[key1525] = val1526; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1532 in this.success) { - if (this.success.hasOwnProperty(kiter1532)) { - let viter1533 = this.success[kiter1532]; - output.writeI64(kiter1532); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1533)); - for (let kiter1534 in viter1533) { - if (viter1533.hasOwnProperty(kiter1534)) { - let viter1535 = viter1533[kiter1534]; - output.writeString(kiter1534); - viter1535.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCcl_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31537 = input.readListBegin(); - const _size1536 = _rtmp31537.size || 0; - for (let _i1538 = 0; _i1538 < _size1536; ++_i1538) { - let elem1539 = null; - elem1539 = input.readString(); - this.keys.push(elem1539); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCcl_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1540 in this.keys) { - if (this.keys.hasOwnProperty(iter1540)) { - iter1540 = this.keys[iter1540]; - output.writeString(iter1540); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31542 = input.readMapBegin(); - const _size1541 = _rtmp31542.size || 0; - for (let _i1543 = 0; _i1543 < _size1541; ++_i1543) { - let key1544 = null; - let val1545 = null; - key1544 = input.readI64(); - val1545 = {}; - const _rtmp31547 = input.readMapBegin(); - const _size1546 = _rtmp31547.size || 0; - for (let _i1548 = 0; _i1548 < _size1546; ++_i1548) { - let key1549 = null; - let val1550 = null; - key1549 = input.readString(); - val1550 = new data_ttypes.TObject(); - val1550.read(input); - val1545[key1549] = val1550; - } - input.readMapEnd(); - this.success[key1544] = val1545; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1551 in this.success) { - if (this.success.hasOwnProperty(kiter1551)) { - let viter1552 = this.success[kiter1551]; - output.writeI64(kiter1551); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1552)); - for (let kiter1553 in viter1552) { - if (viter1552.hasOwnProperty(kiter1553)) { - let viter1554 = viter1552[kiter1553]; - output.writeString(kiter1553); - viter1554.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCriteriaTime_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31556 = input.readListBegin(); - const _size1555 = _rtmp31556.size || 0; - for (let _i1557 = 0; _i1557 < _size1555; ++_i1557) { - let elem1558 = null; - elem1558 = input.readString(); - this.keys.push(elem1558); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCriteriaTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1559 in this.keys) { - if (this.keys.hasOwnProperty(iter1559)) { - iter1559 = this.keys[iter1559]; - output.writeString(iter1559); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31561 = input.readMapBegin(); - const _size1560 = _rtmp31561.size || 0; - for (let _i1562 = 0; _i1562 < _size1560; ++_i1562) { - let key1563 = null; - let val1564 = null; - key1563 = input.readI64(); - val1564 = {}; - const _rtmp31566 = input.readMapBegin(); - const _size1565 = _rtmp31566.size || 0; - for (let _i1567 = 0; _i1567 < _size1565; ++_i1567) { - let key1568 = null; - let val1569 = null; - key1568 = input.readString(); - val1569 = new data_ttypes.TObject(); - val1569.read(input); - val1564[key1568] = val1569; - } - input.readMapEnd(); - this.success[key1563] = val1564; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1570 in this.success) { - if (this.success.hasOwnProperty(kiter1570)) { - let viter1571 = this.success[kiter1570]; - output.writeI64(kiter1570); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1571)); - for (let kiter1572 in viter1571) { - if (viter1571.hasOwnProperty(kiter1572)) { - let viter1573 = viter1571[kiter1572]; - output.writeString(kiter1572); - viter1573.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCriteriaTimestr_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31575 = input.readListBegin(); - const _size1574 = _rtmp31575.size || 0; - for (let _i1576 = 0; _i1576 < _size1574; ++_i1576) { - let elem1577 = null; - elem1577 = input.readString(); - this.keys.push(elem1577); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCriteriaTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1578 in this.keys) { - if (this.keys.hasOwnProperty(iter1578)) { - iter1578 = this.keys[iter1578]; - output.writeString(iter1578); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31580 = input.readMapBegin(); - const _size1579 = _rtmp31580.size || 0; - for (let _i1581 = 0; _i1581 < _size1579; ++_i1581) { - let key1582 = null; - let val1583 = null; - key1582 = input.readI64(); - val1583 = {}; - const _rtmp31585 = input.readMapBegin(); - const _size1584 = _rtmp31585.size || 0; - for (let _i1586 = 0; _i1586 < _size1584; ++_i1586) { - let key1587 = null; - let val1588 = null; - key1587 = input.readString(); - val1588 = new data_ttypes.TObject(); - val1588.read(input); - val1583[key1587] = val1588; - } - input.readMapEnd(); - this.success[key1582] = val1583; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1589 in this.success) { - if (this.success.hasOwnProperty(kiter1589)) { - let viter1590 = this.success[kiter1589]; - output.writeI64(kiter1589); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1590)); - for (let kiter1591 in viter1590) { - if (viter1590.hasOwnProperty(kiter1591)) { - let viter1592 = viter1590[kiter1591]; - output.writeString(kiter1591); - viter1592.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCclTime_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31594 = input.readListBegin(); - const _size1593 = _rtmp31594.size || 0; - for (let _i1595 = 0; _i1595 < _size1593; ++_i1595) { - let elem1596 = null; - elem1596 = input.readString(); - this.keys.push(elem1596); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCclTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1597 in this.keys) { - if (this.keys.hasOwnProperty(iter1597)) { - iter1597 = this.keys[iter1597]; - output.writeString(iter1597); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31599 = input.readMapBegin(); - const _size1598 = _rtmp31599.size || 0; - for (let _i1600 = 0; _i1600 < _size1598; ++_i1600) { - let key1601 = null; - let val1602 = null; - key1601 = input.readI64(); - val1602 = {}; - const _rtmp31604 = input.readMapBegin(); - const _size1603 = _rtmp31604.size || 0; - for (let _i1605 = 0; _i1605 < _size1603; ++_i1605) { - let key1606 = null; - let val1607 = null; - key1606 = input.readString(); - val1607 = new data_ttypes.TObject(); - val1607.read(input); - val1602[key1606] = val1607; - } - input.readMapEnd(); - this.success[key1601] = val1602; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1608 in this.success) { - if (this.success.hasOwnProperty(kiter1608)) { - let viter1609 = this.success[kiter1608]; - output.writeI64(kiter1608); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1609)); - for (let kiter1610 in viter1609) { - if (viter1609.hasOwnProperty(kiter1610)) { - let viter1611 = viter1609[kiter1610]; - output.writeString(kiter1610); - viter1611.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCclTimestr_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31613 = input.readListBegin(); - const _size1612 = _rtmp31613.size || 0; - for (let _i1614 = 0; _i1614 < _size1612; ++_i1614) { - let elem1615 = null; - elem1615 = input.readString(); - this.keys.push(elem1615); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCclTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1616 in this.keys) { - if (this.keys.hasOwnProperty(iter1616)) { - iter1616 = this.keys[iter1616]; - output.writeString(iter1616); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getKeysCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31618 = input.readMapBegin(); - const _size1617 = _rtmp31618.size || 0; - for (let _i1619 = 0; _i1619 < _size1617; ++_i1619) { - let key1620 = null; - let val1621 = null; - key1620 = input.readI64(); - val1621 = {}; - const _rtmp31623 = input.readMapBegin(); - const _size1622 = _rtmp31623.size || 0; - for (let _i1624 = 0; _i1624 < _size1622; ++_i1624) { - let key1625 = null; - let val1626 = null; - key1625 = input.readString(); - val1626 = new data_ttypes.TObject(); - val1626.read(input); - val1621[key1625] = val1626; - } - input.readMapEnd(); - this.success[key1620] = val1621; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getKeysCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1627 in this.success) { - if (this.success.hasOwnProperty(kiter1627)) { - let viter1628 = this.success[kiter1627]; - output.writeI64(kiter1627); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.STRUCT, Thrift.objectLength(viter1628)); - for (let kiter1629 in viter1628) { - if (viter1628.hasOwnProperty(kiter1629)) { - let viter1630 = viter1628[kiter1629]; - output.writeString(kiter1629); - viter1630.write(output); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyKeyValueRecord_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyKeyValueRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyKeyValueRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyKeyValueRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyKeyValueRecordTime_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyKeyValueRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyKeyValueRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyKeyValueRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyKeyValueRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyKeyValueRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyKeyValueRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyKeyValueRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_jsonifyRecords_args = class { - constructor(args) { - this.records = null; - this.identifier = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.identifier !== undefined && args.identifier !== null) { - this.identifier = args.identifier; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31632 = input.readListBegin(); - const _size1631 = _rtmp31632.size || 0; - for (let _i1633 = 0; _i1633 < _size1631; ++_i1633) { - let elem1634 = null; - elem1634 = input.readI64(); - this.records.push(elem1634); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.BOOL) { - this.identifier = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_jsonifyRecords_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1635 in this.records) { - if (this.records.hasOwnProperty(iter1635)) { - iter1635 = this.records[iter1635]; - output.writeI64(iter1635); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.identifier !== null && this.identifier !== undefined) { - output.writeFieldBegin('identifier', Thrift.Type.BOOL, 2); - output.writeBool(this.identifier); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_jsonifyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRING) { - this.success = input.readString(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_jsonifyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRING, 0); - output.writeString(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_jsonifyRecordsTime_args = class { - constructor(args) { - this.records = null; - this.timestamp = null; - this.identifier = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.identifier !== undefined && args.identifier !== null) { - this.identifier = args.identifier; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31637 = input.readListBegin(); - const _size1636 = _rtmp31637.size || 0; - for (let _i1638 = 0; _i1638 < _size1636; ++_i1638) { - let elem1639 = null; - elem1639 = input.readI64(); - this.records.push(elem1639); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.BOOL) { - this.identifier = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_jsonifyRecordsTime_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1640 in this.records) { - if (this.records.hasOwnProperty(iter1640)) { - iter1640 = this.records[iter1640]; - output.writeI64(iter1640); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.identifier !== null && this.identifier !== undefined) { - output.writeFieldBegin('identifier', Thrift.Type.BOOL, 3); - output.writeBool(this.identifier); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_jsonifyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRING) { - this.success = input.readString(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_jsonifyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRING, 0); - output.writeString(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_jsonifyRecordsTimestr_args = class { - constructor(args) { - this.records = null; - this.timestamp = null; - this.identifier = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.identifier !== undefined && args.identifier !== null) { - this.identifier = args.identifier; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31642 = input.readListBegin(); - const _size1641 = _rtmp31642.size || 0; - for (let _i1643 = 0; _i1643 < _size1641; ++_i1643) { - let elem1644 = null; - elem1644 = input.readI64(); - this.records.push(elem1644); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.BOOL) { - this.identifier = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_jsonifyRecordsTimestr_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1645 in this.records) { - if (this.records.hasOwnProperty(iter1645)) { - iter1645 = this.records[iter1645]; - output.writeI64(iter1645); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.identifier !== null && this.identifier !== undefined) { - output.writeFieldBegin('identifier', Thrift.Type.BOOL, 3); - output.writeBool(this.identifier); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_jsonifyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRING) { - this.success = input.readString(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_jsonifyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRING, 0); - output.writeString(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findCriteria_args = class { - constructor(args) { - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findCriteria_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31647 = input.readSetBegin(); - const _size1646 = _rtmp31647.size || 0; - for (let _i1648 = 0; _i1648 < _size1646; ++_i1648) { - let elem1649 = null; - elem1649 = input.readI64(); - this.success.push(elem1649); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1650 in this.success) { - if (this.success.hasOwnProperty(iter1650)) { - iter1650 = this.success[iter1650]; - output.writeI64(iter1650); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findCcl_args = class { - constructor(args) { - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findCcl_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31652 = input.readSetBegin(); - const _size1651 = _rtmp31652.size || 0; - for (let _i1653 = 0; _i1653 < _size1651; ++_i1653) { - let elem1654 = null; - elem1654 = input.readI64(); - this.success.push(elem1654); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1655 in this.success) { - if (this.success.hasOwnProperty(iter1655)) { - iter1655 = this.success[iter1655]; - output.writeI64(iter1655); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorValues_args = class { - constructor(args) { - this.key = null; - this.operator = null; - this.values = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.operator !== undefined && args.operator !== null) { - this.operator = args.operator; - } - if (args.values !== undefined && args.values !== null) { - this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I32) { - this.operator = input.readI32(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.values = []; - const _rtmp31657 = input.readListBegin(); - const _size1656 = _rtmp31657.size || 0; - for (let _i1658 = 0; _i1658 < _size1656; ++_i1658) { - let elem1659 = null; - elem1659 = new data_ttypes.TObject(); - elem1659.read(input); - this.values.push(elem1659); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorValues_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.operator !== null && this.operator !== undefined) { - output.writeFieldBegin('operator', Thrift.Type.I32, 2); - output.writeI32(this.operator); - output.writeFieldEnd(); - } - if (this.values !== null && this.values !== undefined) { - output.writeFieldBegin('values', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.values.length); - for (let iter1660 in this.values) { - if (this.values.hasOwnProperty(iter1660)) { - iter1660 = this.values[iter1660]; - iter1660.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorValues_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31662 = input.readSetBegin(); - const _size1661 = _rtmp31662.size || 0; - for (let _i1663 = 0; _i1663 < _size1661; ++_i1663) { - let elem1664 = null; - elem1664 = input.readI64(); - this.success.push(elem1664); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorValues_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1665 in this.success) { - if (this.success.hasOwnProperty(iter1665)) { - iter1665 = this.success[iter1665]; - output.writeI64(iter1665); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorValuesTime_args = class { - constructor(args) { - this.key = null; - this.operator = null; - this.values = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.operator !== undefined && args.operator !== null) { - this.operator = args.operator; - } - if (args.values !== undefined && args.values !== null) { - this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I32) { - this.operator = input.readI32(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.values = []; - const _rtmp31667 = input.readListBegin(); - const _size1666 = _rtmp31667.size || 0; - for (let _i1668 = 0; _i1668 < _size1666; ++_i1668) { - let elem1669 = null; - elem1669 = new data_ttypes.TObject(); - elem1669.read(input); - this.values.push(elem1669); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorValuesTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.operator !== null && this.operator !== undefined) { - output.writeFieldBegin('operator', Thrift.Type.I32, 2); - output.writeI32(this.operator); - output.writeFieldEnd(); - } - if (this.values !== null && this.values !== undefined) { - output.writeFieldBegin('values', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.values.length); - for (let iter1670 in this.values) { - if (this.values.hasOwnProperty(iter1670)) { - iter1670 = this.values[iter1670]; - iter1670.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorValuesTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31672 = input.readSetBegin(); - const _size1671 = _rtmp31672.size || 0; - for (let _i1673 = 0; _i1673 < _size1671; ++_i1673) { - let elem1674 = null; - elem1674 = input.readI64(); - this.success.push(elem1674); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorValuesTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1675 in this.success) { - if (this.success.hasOwnProperty(iter1675)) { - iter1675 = this.success[iter1675]; - output.writeI64(iter1675); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorValuesTimestr_args = class { - constructor(args) { - this.key = null; - this.operator = null; - this.values = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.operator !== undefined && args.operator !== null) { - this.operator = args.operator; - } - if (args.values !== undefined && args.values !== null) { - this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I32) { - this.operator = input.readI32(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.values = []; - const _rtmp31677 = input.readListBegin(); - const _size1676 = _rtmp31677.size || 0; - for (let _i1678 = 0; _i1678 < _size1676; ++_i1678) { - let elem1679 = null; - elem1679 = new data_ttypes.TObject(); - elem1679.read(input); - this.values.push(elem1679); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorValuesTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.operator !== null && this.operator !== undefined) { - output.writeFieldBegin('operator', Thrift.Type.I32, 2); - output.writeI32(this.operator); - output.writeFieldEnd(); - } - if (this.values !== null && this.values !== undefined) { - output.writeFieldBegin('values', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.values.length); - for (let iter1680 in this.values) { - if (this.values.hasOwnProperty(iter1680)) { - iter1680 = this.values[iter1680]; - iter1680.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorValuesTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31682 = input.readSetBegin(); - const _size1681 = _rtmp31682.size || 0; - for (let _i1683 = 0; _i1683 < _size1681; ++_i1683) { - let elem1684 = null; - elem1684 = input.readI64(); - this.success.push(elem1684); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorValuesTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1685 in this.success) { - if (this.success.hasOwnProperty(iter1685)) { - iter1685 = this.success[iter1685]; - output.writeI64(iter1685); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorstrValues_args = class { - constructor(args) { - this.key = null; - this.operator = null; - this.values = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.operator !== undefined && args.operator !== null) { - this.operator = args.operator; - } - if (args.values !== undefined && args.values !== null) { - this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.operator = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.values = []; - const _rtmp31687 = input.readListBegin(); - const _size1686 = _rtmp31687.size || 0; - for (let _i1688 = 0; _i1688 < _size1686; ++_i1688) { - let elem1689 = null; - elem1689 = new data_ttypes.TObject(); - elem1689.read(input); - this.values.push(elem1689); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorstrValues_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.operator !== null && this.operator !== undefined) { - output.writeFieldBegin('operator', Thrift.Type.STRING, 2); - output.writeString(this.operator); - output.writeFieldEnd(); - } - if (this.values !== null && this.values !== undefined) { - output.writeFieldBegin('values', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.values.length); - for (let iter1690 in this.values) { - if (this.values.hasOwnProperty(iter1690)) { - iter1690 = this.values[iter1690]; - iter1690.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorstrValues_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31692 = input.readSetBegin(); - const _size1691 = _rtmp31692.size || 0; - for (let _i1693 = 0; _i1693 < _size1691; ++_i1693) { - let elem1694 = null; - elem1694 = input.readI64(); - this.success.push(elem1694); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorstrValues_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1695 in this.success) { - if (this.success.hasOwnProperty(iter1695)) { - iter1695 = this.success[iter1695]; - output.writeI64(iter1695); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorstrValuesTime_args = class { - constructor(args) { - this.key = null; - this.operator = null; - this.values = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.operator !== undefined && args.operator !== null) { - this.operator = args.operator; - } - if (args.values !== undefined && args.values !== null) { - this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.operator = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.values = []; - const _rtmp31697 = input.readListBegin(); - const _size1696 = _rtmp31697.size || 0; - for (let _i1698 = 0; _i1698 < _size1696; ++_i1698) { - let elem1699 = null; - elem1699 = new data_ttypes.TObject(); - elem1699.read(input); - this.values.push(elem1699); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.operator !== null && this.operator !== undefined) { - output.writeFieldBegin('operator', Thrift.Type.STRING, 2); - output.writeString(this.operator); - output.writeFieldEnd(); - } - if (this.values !== null && this.values !== undefined) { - output.writeFieldBegin('values', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.values.length); - for (let iter1700 in this.values) { - if (this.values.hasOwnProperty(iter1700)) { - iter1700 = this.values[iter1700]; - iter1700.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 4); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorstrValuesTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31702 = input.readSetBegin(); - const _size1701 = _rtmp31702.size || 0; - for (let _i1703 = 0; _i1703 < _size1701; ++_i1703) { - let elem1704 = null; - elem1704 = input.readI64(); - this.success.push(elem1704); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1705 in this.success) { - if (this.success.hasOwnProperty(iter1705)) { - iter1705 = this.success[iter1705]; - output.writeI64(iter1705); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorstrValuesTimestr_args = class { - constructor(args) { - this.key = null; - this.operator = null; - this.values = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.operator !== undefined && args.operator !== null) { - this.operator = args.operator; - } - if (args.values !== undefined && args.values !== null) { - this.values = Thrift.copyList(args.values, [data_ttypes.TObject]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.operator = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.values = []; - const _rtmp31707 = input.readListBegin(); - const _size1706 = _rtmp31707.size || 0; - for (let _i1708 = 0; _i1708 < _size1706; ++_i1708) { - let elem1709 = null; - elem1709 = new data_ttypes.TObject(); - elem1709.read(input); - this.values.push(elem1709); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.operator !== null && this.operator !== undefined) { - output.writeFieldBegin('operator', Thrift.Type.STRING, 2); - output.writeString(this.operator); - output.writeFieldEnd(); - } - if (this.values !== null && this.values !== undefined) { - output.writeFieldBegin('values', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.values.length); - for (let iter1710 in this.values) { - if (this.values.hasOwnProperty(iter1710)) { - iter1710 = this.values[iter1710]; - iter1710.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 4); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findKeyOperatorstrValuesTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31712 = input.readSetBegin(); - const _size1711 = _rtmp31712.size || 0; - for (let _i1713 = 0; _i1713 < _size1711; ++_i1713) { - let elem1714 = null; - elem1714 = input.readI64(); - this.success.push(elem1714); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findKeyOperatorstrValuesTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1715 in this.success) { - if (this.success.hasOwnProperty(iter1715)) { - iter1715 = this.success[iter1715]; - output.writeI64(iter1715); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_search_args = class { - constructor(args) { - this.key = null; - this.query = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.query !== undefined && args.query !== null) { - this.query = args.query; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.query = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_search_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.query !== null && this.query !== undefined) { - output.writeFieldBegin('query', Thrift.Type.STRING, 2); - output.writeString(this.query); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_search_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyList(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.SET) { - this.success = []; - const _rtmp31717 = input.readSetBegin(); - const _size1716 = _rtmp31717.size || 0; - for (let _i1718 = 0; _i1718 < _size1716; ++_i1718) { - let elem1719 = null; - elem1719 = input.readI64(); - this.success.push(elem1719); - } - input.readSetEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_search_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.SET, 0); - output.writeSetBegin(Thrift.Type.I64, this.success.length); - for (let iter1720 in this.success) { - if (this.success.hasOwnProperty(iter1720)) { - iter1720 = this.success[iter1720]; - output.writeI64(iter1720); - } - } - output.writeSetEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordsTime_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31722 = input.readListBegin(); - const _size1721 = _rtmp31722.size || 0; - for (let _i1723 = 0; _i1723 < _size1721; ++_i1723) { - let elem1724 = null; - elem1724 = input.readString(); - this.keys.push(elem1724); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31726 = input.readListBegin(); - const _size1725 = _rtmp31726.size || 0; - for (let _i1727 = 0; _i1727 < _size1725; ++_i1727) { - let elem1728 = null; - elem1728 = input.readI64(); - this.records.push(elem1728); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordsTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1729 in this.keys) { - if (this.keys.hasOwnProperty(iter1729)) { - iter1729 = this.keys[iter1729]; - output.writeString(iter1729); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1730 in this.records) { - if (this.records.hasOwnProperty(iter1730)) { - iter1730 = this.records[iter1730]; - output.writeI64(iter1730); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordsTime_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordsTime_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordsTimestr_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31732 = input.readListBegin(); - const _size1731 = _rtmp31732.size || 0; - for (let _i1733 = 0; _i1733 < _size1731; ++_i1733) { - let elem1734 = null; - elem1734 = input.readString(); - this.keys.push(elem1734); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31736 = input.readListBegin(); - const _size1735 = _rtmp31736.size || 0; - for (let _i1737 = 0; _i1737 < _size1735; ++_i1737) { - let elem1738 = null; - elem1738 = input.readI64(); - this.records.push(elem1738); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordsTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1739 in this.keys) { - if (this.keys.hasOwnProperty(iter1739)) { - iter1739 = this.keys[iter1739]; - output.writeString(iter1739); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1740 in this.records) { - if (this.records.hasOwnProperty(iter1740)) { - iter1740 = this.records[iter1740]; - output.writeI64(iter1740); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordsTimestr_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordsTimestr_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordTime_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31742 = input.readListBegin(); - const _size1741 = _rtmp31742.size || 0; - for (let _i1743 = 0; _i1743 < _size1741; ++_i1743) { - let elem1744 = null; - elem1744 = input.readString(); - this.keys.push(elem1744); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1745 in this.keys) { - if (this.keys.hasOwnProperty(iter1745)) { - iter1745 = this.keys[iter1745]; - output.writeString(iter1745); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordTime_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordTime_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordTimestr_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31747 = input.readListBegin(); - const _size1746 = _rtmp31747.size || 0; - for (let _i1748 = 0; _i1748 < _size1746; ++_i1748) { - let elem1749 = null; - elem1749 = input.readString(); - this.keys.push(elem1749); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1750 in this.keys) { - if (this.keys.hasOwnProperty(iter1750)) { - iter1750 = this.keys[iter1750]; - output.writeString(iter1750); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeysRecordTimestr_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeysRecordTimestr_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31752 = input.readListBegin(); - const _size1751 = _rtmp31752.size || 0; - for (let _i1753 = 0; _i1753 < _size1751; ++_i1753) { - let elem1754 = null; - elem1754 = input.readI64(); - this.records.push(elem1754); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1755 in this.records) { - if (this.records.hasOwnProperty(iter1755)) { - iter1755 = this.records[iter1755]; - output.writeI64(iter1755); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordsTime_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordsTime_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31757 = input.readListBegin(); - const _size1756 = _rtmp31757.size || 0; - for (let _i1758 = 0; _i1758 < _size1756; ++_i1758) { - let elem1759 = null; - elem1759 = input.readI64(); - this.records.push(elem1759); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1760 in this.records) { - if (this.records.hasOwnProperty(iter1760)) { - iter1760 = this.records[iter1760]; - output.writeI64(iter1760); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordsTimestr_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordsTimestr_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordTime_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordTime_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_revertKeyRecordTimestr_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_revertKeyRecordTimestr_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_pingRecords_args = class { - constructor(args) { - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31762 = input.readListBegin(); - const _size1761 = _rtmp31762.size || 0; - for (let _i1763 = 0; _i1763 < _size1761; ++_i1763) { - let elem1764 = null; - elem1764 = input.readI64(); - this.records.push(elem1764); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_pingRecords_args'); - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1765 in this.records) { - if (this.records.hasOwnProperty(iter1765)) { - iter1765 = this.records[iter1765]; - output.writeI64(iter1765); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_pingRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [null]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31767 = input.readMapBegin(); - const _size1766 = _rtmp31767.size || 0; - for (let _i1768 = 0; _i1768 < _size1766; ++_i1768) { - let key1769 = null; - let val1770 = null; - key1769 = input.readI64(); - val1770 = input.readBool(); - this.success[key1769] = val1770; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_pingRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.BOOL, Thrift.objectLength(this.success)); - for (let kiter1771 in this.success) { - if (this.success.hasOwnProperty(kiter1771)) { - let viter1772 = this.success[kiter1771]; - output.writeI64(kiter1771); - output.writeBool(viter1772); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_pingRecord_args = class { - constructor(args) { - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_pingRecord_args'); - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 1); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_pingRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_pingRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyAndSwap_args = class { - constructor(args) { - this.key = null; - this.expected = null; - this.record = null; - this.replacement = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.expected !== undefined && args.expected !== null) { - this.expected = new data_ttypes.TObject(args.expected); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.replacement !== undefined && args.replacement !== null) { - this.replacement = new data_ttypes.TObject(args.replacement); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.expected = new data_ttypes.TObject(); - this.expected.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.replacement = new data_ttypes.TObject(); - this.replacement.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 7: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyAndSwap_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.expected !== null && this.expected !== undefined) { - output.writeFieldBegin('expected', Thrift.Type.STRUCT, 2); - this.expected.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.replacement !== null && this.replacement !== undefined) { - output.writeFieldBegin('replacement', Thrift.Type.STRUCT, 4); - this.replacement.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 5); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 6); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 7); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyAndSwap_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.BOOL) { - this.success = input.readBool(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyAndSwap_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.BOOL, 0); - output.writeBool(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyOrSet_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyOrSet_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 3); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_verifyOrSet_result = class { - constructor(args) { - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.InvalidArgumentException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_verifyOrSet_result'); - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findOrAddKeyValue_args = class { - constructor(args) { - this.key = null; - this.value = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.value !== undefined && args.value !== null) { - this.value = new data_ttypes.TObject(args.value); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.value = new data_ttypes.TObject(); - this.value.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findOrAddKeyValue_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.value !== null && this.value !== undefined) { - output.writeFieldBegin('value', Thrift.Type.STRUCT, 2); - this.value.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findOrAddKeyValue_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - this.ex5 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.DuplicateEntryException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.InvalidArgumentException) { - this.ex4 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex5 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - if (args.ex5 !== undefined && args.ex5 !== null) { - this.ex5 = args.ex5; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.DuplicateEntryException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.InvalidArgumentException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.ex5 = new exceptions_ttypes.PermissionException(); - this.ex5.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findOrAddKeyValue_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - if (this.ex5 !== null && this.ex5 !== undefined) { - output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); - this.ex5.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findOrInsertCriteriaJson_args = class { - constructor(args) { - this.criteria = null; - this.json = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.json !== undefined && args.json !== null) { - this.json = args.json; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.json = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findOrInsertCriteriaJson_args'); - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 1); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.json !== null && this.json !== undefined) { - output.writeFieldBegin('json', Thrift.Type.STRING, 2); - output.writeString(this.json); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findOrInsertCriteriaJson_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.DuplicateEntryException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.DuplicateEntryException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findOrInsertCriteriaJson_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findOrInsertCclJson_args = class { - constructor(args) { - this.ccl = null; - this.json = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.json !== undefined && args.json !== null) { - this.json = args.json; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.json = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findOrInsertCclJson_args'); - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 1); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.json !== null && this.json !== undefined) { - output.writeFieldBegin('json', Thrift.Type.STRING, 2); - output.writeString(this.json); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_findOrInsertCclJson_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - this.ex5 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.DuplicateEntryException) { - this.ex4 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex5 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - if (args.ex5 !== undefined && args.ex5 !== null) { - this.ex5 = args.ex5; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.DuplicateEntryException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.ex5 = new exceptions_ttypes.PermissionException(); - this.ex5.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_findOrInsertCclJson_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - if (this.ex5 !== null && this.ex5 !== undefined) { - output.writeFieldBegin('ex5', Thrift.Type.STRUCT, 5); - this.ex5.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31774 = input.readListBegin(); - const _size1773 = _rtmp31774.size || 0; - for (let _i1775 = 0; _i1775 < _size1773; ++_i1775) { - let elem1776 = null; - elem1776 = input.readI64(); - this.records.push(elem1776); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1777 in this.records) { - if (this.records.hasOwnProperty(iter1777)) { - iter1777 = this.records[iter1777]; - output.writeI64(iter1777); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31779 = input.readListBegin(); - const _size1778 = _rtmp31779.size || 0; - for (let _i1780 = 0; _i1780 < _size1778; ++_i1780) { - let elem1781 = null; - elem1781 = input.readI64(); - this.records.push(elem1781); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1782 in this.records) { - if (this.records.hasOwnProperty(iter1782)) { - iter1782 = this.records[iter1782]; - output.writeI64(iter1782); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31784 = input.readListBegin(); - const _size1783 = _rtmp31784.size || 0; - for (let _i1785 = 0; _i1785 < _size1783; ++_i1785) { - let elem1786 = null; - elem1786 = input.readI64(); - this.records.push(elem1786); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1787 in this.records) { - if (this.records.hasOwnProperty(iter1787)) { - iter1787 = this.records[iter1787]; - output.writeI64(iter1787); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKey_args = class { - constructor(args) { - this.key = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKey_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKey_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKey_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyTime_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyTimestr_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_sumKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_sumKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31789 = input.readListBegin(); - const _size1788 = _rtmp31789.size || 0; - for (let _i1790 = 0; _i1790 < _size1788; ++_i1790) { - let elem1791 = null; - elem1791 = input.readI64(); - this.records.push(elem1791); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1792 in this.records) { - if (this.records.hasOwnProperty(iter1792)) { - iter1792 = this.records[iter1792]; - output.writeI64(iter1792); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31794 = input.readListBegin(); - const _size1793 = _rtmp31794.size || 0; - for (let _i1795 = 0; _i1795 < _size1793; ++_i1795) { - let elem1796 = null; - elem1796 = input.readI64(); - this.records.push(elem1796); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1797 in this.records) { - if (this.records.hasOwnProperty(iter1797)) { - iter1797 = this.records[iter1797]; - output.writeI64(iter1797); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31799 = input.readListBegin(); - const _size1798 = _rtmp31799.size || 0; - for (let _i1800 = 0; _i1800 < _size1798; ++_i1800) { - let elem1801 = null; - elem1801 = input.readI64(); - this.records.push(elem1801); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1802 in this.records) { - if (this.records.hasOwnProperty(iter1802)) { - iter1802 = this.records[iter1802]; - output.writeI64(iter1802); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKey_args = class { - constructor(args) { - this.key = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKey_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKey_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKey_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyTime_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyTimestr_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_averageKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_averageKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31804 = input.readListBegin(); - const _size1803 = _rtmp31804.size || 0; - for (let _i1805 = 0; _i1805 < _size1803; ++_i1805) { - let elem1806 = null; - elem1806 = input.readI64(); - this.records.push(elem1806); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1807 in this.records) { - if (this.records.hasOwnProperty(iter1807)) { - iter1807 = this.records[iter1807]; - output.writeI64(iter1807); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31809 = input.readListBegin(); - const _size1808 = _rtmp31809.size || 0; - for (let _i1810 = 0; _i1810 < _size1808; ++_i1810) { - let elem1811 = null; - elem1811 = input.readI64(); - this.records.push(elem1811); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1812 in this.records) { - if (this.records.hasOwnProperty(iter1812)) { - iter1812 = this.records[iter1812]; - output.writeI64(iter1812); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31814 = input.readListBegin(); - const _size1813 = _rtmp31814.size || 0; - for (let _i1815 = 0; _i1815 < _size1813; ++_i1815) { - let elem1816 = null; - elem1816 = input.readI64(); - this.records.push(elem1816); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1817 in this.records) { - if (this.records.hasOwnProperty(iter1817)) { - iter1817 = this.records[iter1817]; - output.writeI64(iter1817); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKey_args = class { - constructor(args) { - this.key = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKey_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKey_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKey_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyTime_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyTimestr_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_countKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_countKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31819 = input.readListBegin(); - const _size1818 = _rtmp31819.size || 0; - for (let _i1820 = 0; _i1820 < _size1818; ++_i1820) { - let elem1821 = null; - elem1821 = input.readI64(); - this.records.push(elem1821); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1822 in this.records) { - if (this.records.hasOwnProperty(iter1822)) { - iter1822 = this.records[iter1822]; - output.writeI64(iter1822); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31824 = input.readListBegin(); - const _size1823 = _rtmp31824.size || 0; - for (let _i1825 = 0; _i1825 < _size1823; ++_i1825) { - let elem1826 = null; - elem1826 = input.readI64(); - this.records.push(elem1826); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1827 in this.records) { - if (this.records.hasOwnProperty(iter1827)) { - iter1827 = this.records[iter1827]; - output.writeI64(iter1827); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31829 = input.readListBegin(); - const _size1828 = _rtmp31829.size || 0; - for (let _i1830 = 0; _i1830 < _size1828; ++_i1830) { - let elem1831 = null; - elem1831 = input.readI64(); - this.records.push(elem1831); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1832 in this.records) { - if (this.records.hasOwnProperty(iter1832)) { - iter1832 = this.records[iter1832]; - output.writeI64(iter1832); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKey_args = class { - constructor(args) { - this.key = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKey_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKey_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKey_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyTime_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyTimestr_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_maxKeyTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_maxKeyTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKey_args = class { - constructor(args) { - this.key = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKey_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 3); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKey_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKey_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31834 = input.readListBegin(); - const _size1833 = _rtmp31834.size || 0; - for (let _i1835 = 0; _i1835 < _size1833; ++_i1835) { - let elem1836 = null; - elem1836 = input.readI64(); - this.records.push(elem1836); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1837 in this.records) { - if (this.records.hasOwnProperty(iter1837)) { - iter1837 = this.records[iter1837]; - output.writeI64(iter1837); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31839 = input.readListBegin(); - const _size1838 = _rtmp31839.size || 0; - for (let _i1840 = 0; _i1840 < _size1838; ++_i1840) { - let elem1841 = null; - elem1841 = input.readI64(); - this.records.push(elem1841); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1842 in this.records) { - if (this.records.hasOwnProperty(iter1842)) { - iter1842 = this.records[iter1842]; - output.writeI64(iter1842); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyTime_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 2); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyTimestr_args = class { - constructor(args) { - this.key = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 2); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31844 = input.readListBegin(); - const _size1843 = _rtmp31844.size || 0; - for (let _i1845 = 0; _i1845 < _size1843; ++_i1845) { - let elem1846 = null; - elem1846 = input.readI64(); - this.records.push(elem1846); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1847 in this.records) { - if (this.records.hasOwnProperty(iter1847)) { - iter1847 = this.records[iter1847]; - output.writeI64(iter1847); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_minKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new data_ttypes.TObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new data_ttypes.TObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_minKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecord_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecord_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31849 = input.readMapBegin(); - const _size1848 = _rtmp31849.size || 0; - for (let _i1850 = 0; _i1850 < _size1848; ++_i1850) { - let key1851 = null; - let val1852 = null; - key1851 = input.readI64(); - val1852 = []; - const _rtmp31854 = input.readSetBegin(); - const _size1853 = _rtmp31854.size || 0; - for (let _i1855 = 0; _i1855 < _size1853; ++_i1855) { - let elem1856 = null; - elem1856 = new data_ttypes.TObject(); - elem1856.read(input); - val1852.push(elem1856); - } - input.readSetEnd(); - this.success[key1851] = val1852; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1857 in this.success) { - if (this.success.hasOwnProperty(kiter1857)) { - let viter1858 = this.success[kiter1857]; - output.writeI64(kiter1857); - output.writeSetBegin(Thrift.Type.STRUCT, viter1858.length); - for (let iter1859 in viter1858) { - if (viter1858.hasOwnProperty(iter1859)) { - iter1859 = viter1858[iter1859]; - iter1859.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordTime_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31861 = input.readMapBegin(); - const _size1860 = _rtmp31861.size || 0; - for (let _i1862 = 0; _i1862 < _size1860; ++_i1862) { - let key1863 = null; - let val1864 = null; - key1863 = input.readI64(); - val1864 = []; - const _rtmp31866 = input.readSetBegin(); - const _size1865 = _rtmp31866.size || 0; - for (let _i1867 = 0; _i1867 < _size1865; ++_i1867) { - let elem1868 = null; - elem1868 = new data_ttypes.TObject(); - elem1868.read(input); - val1864.push(elem1868); - } - input.readSetEnd(); - this.success[key1863] = val1864; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1869 in this.success) { - if (this.success.hasOwnProperty(kiter1869)) { - let viter1870 = this.success[kiter1869]; - output.writeI64(kiter1869); - output.writeSetBegin(Thrift.Type.STRUCT, viter1870.length); - for (let iter1871 in viter1870) { - if (viter1870.hasOwnProperty(iter1871)) { - iter1871 = viter1870[iter1871]; - iter1871.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordTimestr_args = class { - constructor(args) { - this.key = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31873 = input.readMapBegin(); - const _size1872 = _rtmp31873.size || 0; - for (let _i1874 = 0; _i1874 < _size1872; ++_i1874) { - let key1875 = null; - let val1876 = null; - key1875 = input.readI64(); - val1876 = []; - const _rtmp31878 = input.readSetBegin(); - const _size1877 = _rtmp31878.size || 0; - for (let _i1879 = 0; _i1879 < _size1877; ++_i1879) { - let elem1880 = null; - elem1880 = new data_ttypes.TObject(); - elem1880.read(input); - val1876.push(elem1880); - } - input.readSetEnd(); - this.success[key1875] = val1876; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1881 in this.success) { - if (this.success.hasOwnProperty(kiter1881)) { - let viter1882 = this.success[kiter1881]; - output.writeI64(kiter1881); - output.writeSetBegin(Thrift.Type.STRUCT, viter1882.length); - for (let iter1883 in viter1882) { - if (viter1882.hasOwnProperty(iter1883)) { - iter1883 = viter1882[iter1883]; - iter1883.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecord_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31885 = input.readListBegin(); - const _size1884 = _rtmp31885.size || 0; - for (let _i1886 = 0; _i1886 < _size1884; ++_i1886) { - let elem1887 = null; - elem1887 = input.readString(); - this.keys.push(elem1887); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecord_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1888 in this.keys) { - if (this.keys.hasOwnProperty(iter1888)) { - iter1888 = this.keys[iter1888]; - output.writeString(iter1888); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecord_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31890 = input.readMapBegin(); - const _size1889 = _rtmp31890.size || 0; - for (let _i1891 = 0; _i1891 < _size1889; ++_i1891) { - let key1892 = null; - let val1893 = null; - key1892 = input.readI64(); - val1893 = {}; - const _rtmp31895 = input.readMapBegin(); - const _size1894 = _rtmp31895.size || 0; - for (let _i1896 = 0; _i1896 < _size1894; ++_i1896) { - let key1897 = null; - let val1898 = null; - key1897 = input.readString(); - val1898 = []; - const _rtmp31900 = input.readSetBegin(); - const _size1899 = _rtmp31900.size || 0; - for (let _i1901 = 0; _i1901 < _size1899; ++_i1901) { - let elem1902 = null; - elem1902 = new data_ttypes.TObject(); - elem1902.read(input); - val1898.push(elem1902); - } - input.readSetEnd(); - val1893[key1897] = val1898; - } - input.readMapEnd(); - this.success[key1892] = val1893; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecord_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1903 in this.success) { - if (this.success.hasOwnProperty(kiter1903)) { - let viter1904 = this.success[kiter1903]; - output.writeI64(kiter1903); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1904)); - for (let kiter1905 in viter1904) { - if (viter1904.hasOwnProperty(kiter1905)) { - let viter1906 = viter1904[kiter1905]; - output.writeString(kiter1905); - output.writeSetBegin(Thrift.Type.STRUCT, viter1906.length); - for (let iter1907 in viter1906) { - if (viter1906.hasOwnProperty(iter1907)) { - iter1907 = viter1906[iter1907]; - iter1907.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordTime_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31909 = input.readListBegin(); - const _size1908 = _rtmp31909.size || 0; - for (let _i1910 = 0; _i1910 < _size1908; ++_i1910) { - let elem1911 = null; - elem1911 = input.readString(); - this.keys.push(elem1911); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1912 in this.keys) { - if (this.keys.hasOwnProperty(iter1912)) { - iter1912 = this.keys[iter1912]; - output.writeString(iter1912); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31914 = input.readMapBegin(); - const _size1913 = _rtmp31914.size || 0; - for (let _i1915 = 0; _i1915 < _size1913; ++_i1915) { - let key1916 = null; - let val1917 = null; - key1916 = input.readI64(); - val1917 = {}; - const _rtmp31919 = input.readMapBegin(); - const _size1918 = _rtmp31919.size || 0; - for (let _i1920 = 0; _i1920 < _size1918; ++_i1920) { - let key1921 = null; - let val1922 = null; - key1921 = input.readString(); - val1922 = []; - const _rtmp31924 = input.readSetBegin(); - const _size1923 = _rtmp31924.size || 0; - for (let _i1925 = 0; _i1925 < _size1923; ++_i1925) { - let elem1926 = null; - elem1926 = new data_ttypes.TObject(); - elem1926.read(input); - val1922.push(elem1926); - } - input.readSetEnd(); - val1917[key1921] = val1922; - } - input.readMapEnd(); - this.success[key1916] = val1917; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1927 in this.success) { - if (this.success.hasOwnProperty(kiter1927)) { - let viter1928 = this.success[kiter1927]; - output.writeI64(kiter1927); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1928)); - for (let kiter1929 in viter1928) { - if (viter1928.hasOwnProperty(kiter1929)) { - let viter1930 = viter1928[kiter1929]; - output.writeString(kiter1929); - output.writeSetBegin(Thrift.Type.STRUCT, viter1930.length); - for (let iter1931 in viter1930) { - if (viter1930.hasOwnProperty(iter1931)) { - iter1931 = viter1930[iter1931]; - iter1931.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordTimestr_args = class { - constructor(args) { - this.keys = null; - this.record = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.record !== undefined && args.record !== null) { - this.record = args.record; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31933 = input.readListBegin(); - const _size1932 = _rtmp31933.size || 0; - for (let _i1934 = 0; _i1934 < _size1932; ++_i1934) { - let elem1935 = null; - elem1935 = input.readString(); - this.keys.push(elem1935); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.I64) { - this.record = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1936 in this.keys) { - if (this.keys.hasOwnProperty(iter1936)) { - iter1936 = this.keys[iter1936]; - output.writeString(iter1936); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.record !== null && this.record !== undefined) { - output.writeFieldBegin('record', Thrift.Type.I64, 2); - output.writeI64(this.record); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31938 = input.readMapBegin(); - const _size1937 = _rtmp31938.size || 0; - for (let _i1939 = 0; _i1939 < _size1937; ++_i1939) { - let key1940 = null; - let val1941 = null; - key1940 = input.readI64(); - val1941 = {}; - const _rtmp31943 = input.readMapBegin(); - const _size1942 = _rtmp31943.size || 0; - for (let _i1944 = 0; _i1944 < _size1942; ++_i1944) { - let key1945 = null; - let val1946 = null; - key1945 = input.readString(); - val1946 = []; - const _rtmp31948 = input.readSetBegin(); - const _size1947 = _rtmp31948.size || 0; - for (let _i1949 = 0; _i1949 < _size1947; ++_i1949) { - let elem1950 = null; - elem1950 = new data_ttypes.TObject(); - elem1950.read(input); - val1946.push(elem1950); - } - input.readSetEnd(); - val1941[key1945] = val1946; - } - input.readMapEnd(); - this.success[key1940] = val1941; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1951 in this.success) { - if (this.success.hasOwnProperty(kiter1951)) { - let viter1952 = this.success[kiter1951]; - output.writeI64(kiter1951); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1952)); - for (let kiter1953 in viter1952) { - if (viter1952.hasOwnProperty(kiter1953)) { - let viter1954 = viter1952[kiter1953]; - output.writeString(kiter1953); - output.writeSetBegin(Thrift.Type.STRUCT, viter1954.length); - for (let iter1955 in viter1954) { - if (viter1954.hasOwnProperty(iter1955)) { - iter1955 = viter1954[iter1955]; - iter1955.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecords_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp31957 = input.readListBegin(); - const _size1956 = _rtmp31957.size || 0; - for (let _i1958 = 0; _i1958 < _size1956; ++_i1958) { - let elem1959 = null; - elem1959 = input.readString(); - this.keys.push(elem1959); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31961 = input.readListBegin(); - const _size1960 = _rtmp31961.size || 0; - for (let _i1962 = 0; _i1962 < _size1960; ++_i1962) { - let elem1963 = null; - elem1963 = input.readI64(); - this.records.push(elem1963); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecords_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter1964 in this.keys) { - if (this.keys.hasOwnProperty(iter1964)) { - iter1964 = this.keys[iter1964]; - output.writeString(iter1964); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1965 in this.records) { - if (this.records.hasOwnProperty(iter1965)) { - iter1965 = this.records[iter1965]; - output.writeI64(iter1965); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31967 = input.readMapBegin(); - const _size1966 = _rtmp31967.size || 0; - for (let _i1968 = 0; _i1968 < _size1966; ++_i1968) { - let key1969 = null; - let val1970 = null; - key1969 = input.readI64(); - val1970 = {}; - const _rtmp31972 = input.readMapBegin(); - const _size1971 = _rtmp31972.size || 0; - for (let _i1973 = 0; _i1973 < _size1971; ++_i1973) { - let key1974 = null; - let val1975 = null; - key1974 = input.readString(); - val1975 = []; - const _rtmp31977 = input.readSetBegin(); - const _size1976 = _rtmp31977.size || 0; - for (let _i1978 = 0; _i1978 < _size1976; ++_i1978) { - let elem1979 = null; - elem1979 = new data_ttypes.TObject(); - elem1979.read(input); - val1975.push(elem1979); - } - input.readSetEnd(); - val1970[key1974] = val1975; - } - input.readMapEnd(); - this.success[key1969] = val1970; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter1980 in this.success) { - if (this.success.hasOwnProperty(kiter1980)) { - let viter1981 = this.success[kiter1980]; - output.writeI64(kiter1980); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter1981)); - for (let kiter1982 in viter1981) { - if (viter1981.hasOwnProperty(kiter1982)) { - let viter1983 = viter1981[kiter1982]; - output.writeString(kiter1982); - output.writeSetBegin(Thrift.Type.STRUCT, viter1983.length); - for (let iter1984 in viter1983) { - if (viter1983.hasOwnProperty(iter1984)) { - iter1984 = viter1983[iter1984]; - iter1984.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecords_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp31986 = input.readListBegin(); - const _size1985 = _rtmp31986.size || 0; - for (let _i1987 = 0; _i1987 < _size1985; ++_i1987) { - let elem1988 = null; - elem1988 = input.readI64(); - this.records.push(elem1988); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecords_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter1989 in this.records) { - if (this.records.hasOwnProperty(iter1989)) { - iter1989 = this.records[iter1989]; - output.writeI64(iter1989); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecords_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp31991 = input.readMapBegin(); - const _size1990 = _rtmp31991.size || 0; - for (let _i1992 = 0; _i1992 < _size1990; ++_i1992) { - let key1993 = null; - let val1994 = null; - key1993 = input.readI64(); - val1994 = []; - const _rtmp31996 = input.readSetBegin(); - const _size1995 = _rtmp31996.size || 0; - for (let _i1997 = 0; _i1997 < _size1995; ++_i1997) { - let elem1998 = null; - elem1998 = new data_ttypes.TObject(); - elem1998.read(input); - val1994.push(elem1998); - } - input.readSetEnd(); - this.success[key1993] = val1994; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecords_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter1999 in this.success) { - if (this.success.hasOwnProperty(kiter1999)) { - let viter2000 = this.success[kiter1999]; - output.writeI64(kiter1999); - output.writeSetBegin(Thrift.Type.STRUCT, viter2000.length); - for (let iter2001 in viter2000) { - if (viter2000.hasOwnProperty(iter2001)) { - iter2001 = viter2000[iter2001]; - iter2001.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordsTime_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp32003 = input.readListBegin(); - const _size2002 = _rtmp32003.size || 0; - for (let _i2004 = 0; _i2004 < _size2002; ++_i2004) { - let elem2005 = null; - elem2005 = input.readI64(); - this.records.push(elem2005); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordsTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter2006 in this.records) { - if (this.records.hasOwnProperty(iter2006)) { - iter2006 = this.records[iter2006]; - output.writeI64(iter2006); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32008 = input.readMapBegin(); - const _size2007 = _rtmp32008.size || 0; - for (let _i2009 = 0; _i2009 < _size2007; ++_i2009) { - let key2010 = null; - let val2011 = null; - key2010 = input.readI64(); - val2011 = []; - const _rtmp32013 = input.readSetBegin(); - const _size2012 = _rtmp32013.size || 0; - for (let _i2014 = 0; _i2014 < _size2012; ++_i2014) { - let elem2015 = null; - elem2015 = new data_ttypes.TObject(); - elem2015.read(input); - val2011.push(elem2015); - } - input.readSetEnd(); - this.success[key2010] = val2011; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2016 in this.success) { - if (this.success.hasOwnProperty(kiter2016)) { - let viter2017 = this.success[kiter2016]; - output.writeI64(kiter2016); - output.writeSetBegin(Thrift.Type.STRUCT, viter2017.length); - for (let iter2018 in viter2017) { - if (viter2017.hasOwnProperty(iter2018)) { - iter2018 = viter2017[iter2018]; - iter2018.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordsTimestr_args = class { - constructor(args) { - this.key = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp32020 = input.readListBegin(); - const _size2019 = _rtmp32020.size || 0; - for (let _i2021 = 0; _i2021 < _size2019; ++_i2021) { - let elem2022 = null; - elem2022 = input.readI64(); - this.records.push(elem2022); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordsTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter2023 in this.records) { - if (this.records.hasOwnProperty(iter2023)) { - iter2023 = this.records[iter2023]; - output.writeI64(iter2023); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32025 = input.readMapBegin(); - const _size2024 = _rtmp32025.size || 0; - for (let _i2026 = 0; _i2026 < _size2024; ++_i2026) { - let key2027 = null; - let val2028 = null; - key2027 = input.readI64(); - val2028 = []; - const _rtmp32030 = input.readSetBegin(); - const _size2029 = _rtmp32030.size || 0; - for (let _i2031 = 0; _i2031 < _size2029; ++_i2031) { - let elem2032 = null; - elem2032 = new data_ttypes.TObject(); - elem2032.read(input); - val2028.push(elem2032); - } - input.readSetEnd(); - this.success[key2027] = val2028; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2033 in this.success) { - if (this.success.hasOwnProperty(kiter2033)) { - let viter2034 = this.success[kiter2033]; - output.writeI64(kiter2033); - output.writeSetBegin(Thrift.Type.STRUCT, viter2034.length); - for (let iter2035 in viter2034) { - if (viter2034.hasOwnProperty(iter2035)) { - iter2035 = viter2034[iter2035]; - iter2035.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordsTime_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32037 = input.readListBegin(); - const _size2036 = _rtmp32037.size || 0; - for (let _i2038 = 0; _i2038 < _size2036; ++_i2038) { - let elem2039 = null; - elem2039 = input.readString(); - this.keys.push(elem2039); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp32041 = input.readListBegin(); - const _size2040 = _rtmp32041.size || 0; - for (let _i2042 = 0; _i2042 < _size2040; ++_i2042) { - let elem2043 = null; - elem2043 = input.readI64(); - this.records.push(elem2043); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordsTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2044 in this.keys) { - if (this.keys.hasOwnProperty(iter2044)) { - iter2044 = this.keys[iter2044]; - output.writeString(iter2044); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter2045 in this.records) { - if (this.records.hasOwnProperty(iter2045)) { - iter2045 = this.records[iter2045]; - output.writeI64(iter2045); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordsTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32047 = input.readMapBegin(); - const _size2046 = _rtmp32047.size || 0; - for (let _i2048 = 0; _i2048 < _size2046; ++_i2048) { - let key2049 = null; - let val2050 = null; - key2049 = input.readI64(); - val2050 = {}; - const _rtmp32052 = input.readMapBegin(); - const _size2051 = _rtmp32052.size || 0; - for (let _i2053 = 0; _i2053 < _size2051; ++_i2053) { - let key2054 = null; - let val2055 = null; - key2054 = input.readString(); - val2055 = []; - const _rtmp32057 = input.readSetBegin(); - const _size2056 = _rtmp32057.size || 0; - for (let _i2058 = 0; _i2058 < _size2056; ++_i2058) { - let elem2059 = null; - elem2059 = new data_ttypes.TObject(); - elem2059.read(input); - val2055.push(elem2059); - } - input.readSetEnd(); - val2050[key2054] = val2055; - } - input.readMapEnd(); - this.success[key2049] = val2050; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordsTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2060 in this.success) { - if (this.success.hasOwnProperty(kiter2060)) { - let viter2061 = this.success[kiter2060]; - output.writeI64(kiter2060); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2061)); - for (let kiter2062 in viter2061) { - if (viter2061.hasOwnProperty(kiter2062)) { - let viter2063 = viter2061[kiter2062]; - output.writeString(kiter2062); - output.writeSetBegin(Thrift.Type.STRUCT, viter2063.length); - for (let iter2064 in viter2063) { - if (viter2063.hasOwnProperty(iter2064)) { - iter2064 = viter2063[iter2064]; - iter2064.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordsTimestr_args = class { - constructor(args) { - this.keys = null; - this.records = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.records !== undefined && args.records !== null) { - this.records = Thrift.copyList(args.records, [null]); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32066 = input.readListBegin(); - const _size2065 = _rtmp32066.size || 0; - for (let _i2067 = 0; _i2067 < _size2065; ++_i2067) { - let elem2068 = null; - elem2068 = input.readString(); - this.keys.push(elem2068); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.LIST) { - this.records = []; - const _rtmp32070 = input.readListBegin(); - const _size2069 = _rtmp32070.size || 0; - for (let _i2071 = 0; _i2071 < _size2069; ++_i2071) { - let elem2072 = null; - elem2072 = input.readI64(); - this.records.push(elem2072); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordsTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2073 in this.keys) { - if (this.keys.hasOwnProperty(iter2073)) { - iter2073 = this.keys[iter2073]; - output.writeString(iter2073); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.records !== null && this.records !== undefined) { - output.writeFieldBegin('records', Thrift.Type.LIST, 2); - output.writeListBegin(Thrift.Type.I64, this.records.length); - for (let iter2074 in this.records) { - if (this.records.hasOwnProperty(iter2074)) { - iter2074 = this.records[iter2074]; - output.writeI64(iter2074); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysRecordsTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32076 = input.readMapBegin(); - const _size2075 = _rtmp32076.size || 0; - for (let _i2077 = 0; _i2077 < _size2075; ++_i2077) { - let key2078 = null; - let val2079 = null; - key2078 = input.readI64(); - val2079 = {}; - const _rtmp32081 = input.readMapBegin(); - const _size2080 = _rtmp32081.size || 0; - for (let _i2082 = 0; _i2082 < _size2080; ++_i2082) { - let key2083 = null; - let val2084 = null; - key2083 = input.readString(); - val2084 = []; - const _rtmp32086 = input.readSetBegin(); - const _size2085 = _rtmp32086.size || 0; - for (let _i2087 = 0; _i2087 < _size2085; ++_i2087) { - let elem2088 = null; - elem2088 = new data_ttypes.TObject(); - elem2088.read(input); - val2084.push(elem2088); - } - input.readSetEnd(); - val2079[key2083] = val2084; - } - input.readMapEnd(); - this.success[key2078] = val2079; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysRecordsTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2089 in this.success) { - if (this.success.hasOwnProperty(kiter2089)) { - let viter2090 = this.success[kiter2089]; - output.writeI64(kiter2089); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2090)); - for (let kiter2091 in viter2090) { - if (viter2090.hasOwnProperty(kiter2091)) { - let viter2092 = viter2090[kiter2091]; - output.writeString(kiter2091); - output.writeSetBegin(Thrift.Type.STRUCT, viter2092.length); - for (let iter2093 in viter2092) { - if (viter2092.hasOwnProperty(iter2093)) { - iter2093 = viter2092[iter2093]; - iter2093.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCcl_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCcl_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32095 = input.readMapBegin(); - const _size2094 = _rtmp32095.size || 0; - for (let _i2096 = 0; _i2096 < _size2094; ++_i2096) { - let key2097 = null; - let val2098 = null; - key2097 = input.readI64(); - val2098 = []; - const _rtmp32100 = input.readSetBegin(); - const _size2099 = _rtmp32100.size || 0; - for (let _i2101 = 0; _i2101 < _size2099; ++_i2101) { - let elem2102 = null; - elem2102 = new data_ttypes.TObject(); - elem2102.read(input); - val2098.push(elem2102); - } - input.readSetEnd(); - this.success[key2097] = val2098; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2103 in this.success) { - if (this.success.hasOwnProperty(kiter2103)) { - let viter2104 = this.success[kiter2103]; - output.writeI64(kiter2103); - output.writeSetBegin(Thrift.Type.STRUCT, viter2104.length); - for (let iter2105 in viter2104) { - if (viter2104.hasOwnProperty(iter2105)) { - iter2105 = viter2104[iter2105]; - iter2105.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCclTime_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCclTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32107 = input.readMapBegin(); - const _size2106 = _rtmp32107.size || 0; - for (let _i2108 = 0; _i2108 < _size2106; ++_i2108) { - let key2109 = null; - let val2110 = null; - key2109 = input.readI64(); - val2110 = []; - const _rtmp32112 = input.readSetBegin(); - const _size2111 = _rtmp32112.size || 0; - for (let _i2113 = 0; _i2113 < _size2111; ++_i2113) { - let elem2114 = null; - elem2114 = new data_ttypes.TObject(); - elem2114.read(input); - val2110.push(elem2114); - } - input.readSetEnd(); - this.success[key2109] = val2110; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2115 in this.success) { - if (this.success.hasOwnProperty(kiter2115)) { - let viter2116 = this.success[kiter2115]; - output.writeI64(kiter2115); - output.writeSetBegin(Thrift.Type.STRUCT, viter2116.length); - for (let iter2117 in viter2116) { - if (viter2116.hasOwnProperty(iter2117)) { - iter2117 = viter2116[iter2117]; - iter2117.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCclTimestr_args = class { - constructor(args) { - this.key = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCclTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32119 = input.readMapBegin(); - const _size2118 = _rtmp32119.size || 0; - for (let _i2120 = 0; _i2120 < _size2118; ++_i2120) { - let key2121 = null; - let val2122 = null; - key2121 = input.readI64(); - val2122 = []; - const _rtmp32124 = input.readSetBegin(); - const _size2123 = _rtmp32124.size || 0; - for (let _i2125 = 0; _i2125 < _size2123; ++_i2125) { - let elem2126 = null; - elem2126 = new data_ttypes.TObject(); - elem2126.read(input); - val2122.push(elem2126); - } - input.readSetEnd(); - this.success[key2121] = val2122; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2127 in this.success) { - if (this.success.hasOwnProperty(kiter2127)) { - let viter2128 = this.success[kiter2127]; - output.writeI64(kiter2127); - output.writeSetBegin(Thrift.Type.STRUCT, viter2128.length); - for (let iter2129 in viter2128) { - if (viter2128.hasOwnProperty(iter2129)) { - iter2129 = viter2128[iter2129]; - iter2129.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCcl_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32131 = input.readListBegin(); - const _size2130 = _rtmp32131.size || 0; - for (let _i2132 = 0; _i2132 < _size2130; ++_i2132) { - let elem2133 = null; - elem2133 = input.readString(); - this.keys.push(elem2133); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCcl_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2134 in this.keys) { - if (this.keys.hasOwnProperty(iter2134)) { - iter2134 = this.keys[iter2134]; - output.writeString(iter2134); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCcl_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32136 = input.readMapBegin(); - const _size2135 = _rtmp32136.size || 0; - for (let _i2137 = 0; _i2137 < _size2135; ++_i2137) { - let key2138 = null; - let val2139 = null; - key2138 = input.readI64(); - val2139 = {}; - const _rtmp32141 = input.readMapBegin(); - const _size2140 = _rtmp32141.size || 0; - for (let _i2142 = 0; _i2142 < _size2140; ++_i2142) { - let key2143 = null; - let val2144 = null; - key2143 = input.readString(); - val2144 = []; - const _rtmp32146 = input.readSetBegin(); - const _size2145 = _rtmp32146.size || 0; - for (let _i2147 = 0; _i2147 < _size2145; ++_i2147) { - let elem2148 = null; - elem2148 = new data_ttypes.TObject(); - elem2148.read(input); - val2144.push(elem2148); - } - input.readSetEnd(); - val2139[key2143] = val2144; - } - input.readMapEnd(); - this.success[key2138] = val2139; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCcl_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2149 in this.success) { - if (this.success.hasOwnProperty(kiter2149)) { - let viter2150 = this.success[kiter2149]; - output.writeI64(kiter2149); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2150)); - for (let kiter2151 in viter2150) { - if (viter2150.hasOwnProperty(kiter2151)) { - let viter2152 = viter2150[kiter2151]; - output.writeString(kiter2151); - output.writeSetBegin(Thrift.Type.STRUCT, viter2152.length); - for (let iter2153 in viter2152) { - if (viter2152.hasOwnProperty(iter2153)) { - iter2153 = viter2152[iter2153]; - iter2153.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCclTime_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32155 = input.readListBegin(); - const _size2154 = _rtmp32155.size || 0; - for (let _i2156 = 0; _i2156 < _size2154; ++_i2156) { - let elem2157 = null; - elem2157 = input.readString(); - this.keys.push(elem2157); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCclTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2158 in this.keys) { - if (this.keys.hasOwnProperty(iter2158)) { - iter2158 = this.keys[iter2158]; - output.writeString(iter2158); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCclTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32160 = input.readMapBegin(); - const _size2159 = _rtmp32160.size || 0; - for (let _i2161 = 0; _i2161 < _size2159; ++_i2161) { - let key2162 = null; - let val2163 = null; - key2162 = input.readI64(); - val2163 = {}; - const _rtmp32165 = input.readMapBegin(); - const _size2164 = _rtmp32165.size || 0; - for (let _i2166 = 0; _i2166 < _size2164; ++_i2166) { - let key2167 = null; - let val2168 = null; - key2167 = input.readString(); - val2168 = []; - const _rtmp32170 = input.readSetBegin(); - const _size2169 = _rtmp32170.size || 0; - for (let _i2171 = 0; _i2171 < _size2169; ++_i2171) { - let elem2172 = null; - elem2172 = new data_ttypes.TObject(); - elem2172.read(input); - val2168.push(elem2172); - } - input.readSetEnd(); - val2163[key2167] = val2168; - } - input.readMapEnd(); - this.success[key2162] = val2163; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCclTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2173 in this.success) { - if (this.success.hasOwnProperty(kiter2173)) { - let viter2174 = this.success[kiter2173]; - output.writeI64(kiter2173); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2174)); - for (let kiter2175 in viter2174) { - if (viter2174.hasOwnProperty(kiter2175)) { - let viter2176 = viter2174[kiter2175]; - output.writeString(kiter2175); - output.writeSetBegin(Thrift.Type.STRUCT, viter2176.length); - for (let iter2177 in viter2176) { - if (viter2176.hasOwnProperty(iter2177)) { - iter2177 = viter2176[iter2177]; - iter2177.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCclTimestr_args = class { - constructor(args) { - this.keys = null; - this.ccl = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.ccl !== undefined && args.ccl !== null) { - this.ccl = args.ccl; - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32179 = input.readListBegin(); - const _size2178 = _rtmp32179.size || 0; - for (let _i2180 = 0; _i2180 < _size2178; ++_i2180) { - let elem2181 = null; - elem2181 = input.readString(); - this.keys.push(elem2181); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRING) { - this.ccl = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCclTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2182 in this.keys) { - if (this.keys.hasOwnProperty(iter2182)) { - iter2182 = this.keys[iter2182]; - output.writeString(iter2182); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.ccl !== null && this.ccl !== undefined) { - output.writeFieldBegin('ccl', Thrift.Type.STRING, 2); - output.writeString(this.ccl); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCclTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32184 = input.readMapBegin(); - const _size2183 = _rtmp32184.size || 0; - for (let _i2185 = 0; _i2185 < _size2183; ++_i2185) { - let key2186 = null; - let val2187 = null; - key2186 = input.readI64(); - val2187 = {}; - const _rtmp32189 = input.readMapBegin(); - const _size2188 = _rtmp32189.size || 0; - for (let _i2190 = 0; _i2190 < _size2188; ++_i2190) { - let key2191 = null; - let val2192 = null; - key2191 = input.readString(); - val2192 = []; - const _rtmp32194 = input.readSetBegin(); - const _size2193 = _rtmp32194.size || 0; - for (let _i2195 = 0; _i2195 < _size2193; ++_i2195) { - let elem2196 = null; - elem2196 = new data_ttypes.TObject(); - elem2196.read(input); - val2192.push(elem2196); - } - input.readSetEnd(); - val2187[key2191] = val2192; - } - input.readMapEnd(); - this.success[key2186] = val2187; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCclTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2197 in this.success) { - if (this.success.hasOwnProperty(kiter2197)) { - let viter2198 = this.success[kiter2197]; - output.writeI64(kiter2197); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2198)); - for (let kiter2199 in viter2198) { - if (viter2198.hasOwnProperty(kiter2199)) { - let viter2200 = viter2198[kiter2199]; - output.writeString(kiter2199); - output.writeSetBegin(Thrift.Type.STRUCT, viter2200.length); - for (let iter2201 in viter2200) { - if (viter2200.hasOwnProperty(iter2201)) { - iter2201 = viter2200[iter2201]; - iter2201.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCriteria_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCriteria_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32203 = input.readMapBegin(); - const _size2202 = _rtmp32203.size || 0; - for (let _i2204 = 0; _i2204 < _size2202; ++_i2204) { - let key2205 = null; - let val2206 = null; - key2205 = input.readI64(); - val2206 = []; - const _rtmp32208 = input.readSetBegin(); - const _size2207 = _rtmp32208.size || 0; - for (let _i2209 = 0; _i2209 < _size2207; ++_i2209) { - let elem2210 = null; - elem2210 = new data_ttypes.TObject(); - elem2210.read(input); - val2206.push(elem2210); - } - input.readSetEnd(); - this.success[key2205] = val2206; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2211 in this.success) { - if (this.success.hasOwnProperty(kiter2211)) { - let viter2212 = this.success[kiter2211]; - output.writeI64(kiter2211); - output.writeSetBegin(Thrift.Type.STRUCT, viter2212.length); - for (let iter2213 in viter2212) { - if (viter2212.hasOwnProperty(iter2213)) { - iter2213 = viter2212[iter2213]; - iter2213.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCriteriaTime_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCriteriaTime_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32215 = input.readMapBegin(); - const _size2214 = _rtmp32215.size || 0; - for (let _i2216 = 0; _i2216 < _size2214; ++_i2216) { - let key2217 = null; - let val2218 = null; - key2217 = input.readI64(); - val2218 = []; - const _rtmp32220 = input.readSetBegin(); - const _size2219 = _rtmp32220.size || 0; - for (let _i2221 = 0; _i2221 < _size2219; ++_i2221) { - let elem2222 = null; - elem2222 = new data_ttypes.TObject(); - elem2222.read(input); - val2218.push(elem2222); - } - input.readSetEnd(); - this.success[key2217] = val2218; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2223 in this.success) { - if (this.success.hasOwnProperty(kiter2223)) { - let viter2224 = this.success[kiter2223]; - output.writeI64(kiter2223); - output.writeSetBegin(Thrift.Type.STRUCT, viter2224.length); - for (let iter2225 in viter2224) { - if (viter2224.hasOwnProperty(iter2225)) { - iter2225 = viter2224[iter2225]; - iter2225.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCriteriaTimestr_args = class { - constructor(args) { - this.key = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.key !== undefined && args.key !== null) { - this.key = args.key; - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.key = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCriteriaTimestr_args'); - if (this.key !== null && this.key !== undefined) { - output.writeFieldBegin('key', Thrift.Type.STRING, 1); - output.writeString(this.key); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeyCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32227 = input.readMapBegin(); - const _size2226 = _rtmp32227.size || 0; - for (let _i2228 = 0; _i2228 < _size2226; ++_i2228) { - let key2229 = null; - let val2230 = null; - key2229 = input.readI64(); - val2230 = []; - const _rtmp32232 = input.readSetBegin(); - const _size2231 = _rtmp32232.size || 0; - for (let _i2233 = 0; _i2233 < _size2231; ++_i2233) { - let elem2234 = null; - elem2234 = new data_ttypes.TObject(); - elem2234.read(input); - val2230.push(elem2234); - } - input.readSetEnd(); - this.success[key2229] = val2230; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeyCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.SET, Thrift.objectLength(this.success)); - for (let kiter2235 in this.success) { - if (this.success.hasOwnProperty(kiter2235)) { - let viter2236 = this.success[kiter2235]; - output.writeI64(kiter2235); - output.writeSetBegin(Thrift.Type.STRUCT, viter2236.length); - for (let iter2237 in viter2236) { - if (viter2236.hasOwnProperty(iter2237)) { - iter2237 = viter2236[iter2237]; - iter2237.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCriteria_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32239 = input.readListBegin(); - const _size2238 = _rtmp32239.size || 0; - for (let _i2240 = 0; _i2240 < _size2238; ++_i2240) { - let elem2241 = null; - elem2241 = input.readString(); - this.keys.push(elem2241); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCriteria_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2242 in this.keys) { - if (this.keys.hasOwnProperty(iter2242)) { - iter2242 = this.keys[iter2242]; - output.writeString(iter2242); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 3); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 4); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 5); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCriteria_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32244 = input.readMapBegin(); - const _size2243 = _rtmp32244.size || 0; - for (let _i2245 = 0; _i2245 < _size2243; ++_i2245) { - let key2246 = null; - let val2247 = null; - key2246 = input.readI64(); - val2247 = {}; - const _rtmp32249 = input.readMapBegin(); - const _size2248 = _rtmp32249.size || 0; - for (let _i2250 = 0; _i2250 < _size2248; ++_i2250) { - let key2251 = null; - let val2252 = null; - key2251 = input.readString(); - val2252 = []; - const _rtmp32254 = input.readSetBegin(); - const _size2253 = _rtmp32254.size || 0; - for (let _i2255 = 0; _i2255 < _size2253; ++_i2255) { - let elem2256 = null; - elem2256 = new data_ttypes.TObject(); - elem2256.read(input); - val2252.push(elem2256); - } - input.readSetEnd(); - val2247[key2251] = val2252; - } - input.readMapEnd(); - this.success[key2246] = val2247; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCriteria_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2257 in this.success) { - if (this.success.hasOwnProperty(kiter2257)) { - let viter2258 = this.success[kiter2257]; - output.writeI64(kiter2257); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2258)); - for (let kiter2259 in viter2258) { - if (viter2258.hasOwnProperty(kiter2259)) { - let viter2260 = viter2258[kiter2259]; - output.writeString(kiter2259); - output.writeSetBegin(Thrift.Type.STRUCT, viter2260.length); - for (let iter2261 in viter2260) { - if (viter2260.hasOwnProperty(iter2261)) { - iter2261 = viter2260[iter2261]; - iter2261.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCriteriaTime_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32263 = input.readListBegin(); - const _size2262 = _rtmp32263.size || 0; - for (let _i2264 = 0; _i2264 < _size2262; ++_i2264) { - let elem2265 = null; - elem2265 = input.readString(); - this.keys.push(elem2265); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.I64) { - this.timestamp = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCriteriaTime_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2266 in this.keys) { - if (this.keys.hasOwnProperty(iter2266)) { - iter2266 = this.keys[iter2266]; - output.writeString(iter2266); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.I64, 3); - output.writeI64(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCriteriaTime_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32268 = input.readMapBegin(); - const _size2267 = _rtmp32268.size || 0; - for (let _i2269 = 0; _i2269 < _size2267; ++_i2269) { - let key2270 = null; - let val2271 = null; - key2270 = input.readI64(); - val2271 = {}; - const _rtmp32273 = input.readMapBegin(); - const _size2272 = _rtmp32273.size || 0; - for (let _i2274 = 0; _i2274 < _size2272; ++_i2274) { - let key2275 = null; - let val2276 = null; - key2275 = input.readString(); - val2276 = []; - const _rtmp32278 = input.readSetBegin(); - const _size2277 = _rtmp32278.size || 0; - for (let _i2279 = 0; _i2279 < _size2277; ++_i2279) { - let elem2280 = null; - elem2280 = new data_ttypes.TObject(); - elem2280.read(input); - val2276.push(elem2280); - } - input.readSetEnd(); - val2271[key2275] = val2276; - } - input.readMapEnd(); - this.success[key2270] = val2271; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCriteriaTime_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2281 in this.success) { - if (this.success.hasOwnProperty(kiter2281)) { - let viter2282 = this.success[kiter2281]; - output.writeI64(kiter2281); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2282)); - for (let kiter2283 in viter2282) { - if (viter2282.hasOwnProperty(kiter2283)) { - let viter2284 = viter2282[kiter2283]; - output.writeString(kiter2283); - output.writeSetBegin(Thrift.Type.STRUCT, viter2284.length); - for (let iter2285 in viter2284) { - if (viter2284.hasOwnProperty(iter2285)) { - iter2285 = viter2284[iter2285]; - iter2285.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCriteriaTimestr_args = class { - constructor(args) { - this.keys = null; - this.criteria = null; - this.timestamp = null; - this.creds = null; - this.transaction = null; - this.environment = null; - if (args) { - if (args.keys !== undefined && args.keys !== null) { - this.keys = Thrift.copyList(args.keys, [null]); - } - if (args.criteria !== undefined && args.criteria !== null) { - this.criteria = new data_ttypes.TCriteria(args.criteria); - } - if (args.timestamp !== undefined && args.timestamp !== null) { - this.timestamp = args.timestamp; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.transaction !== undefined && args.transaction !== null) { - this.transaction = new shared_ttypes.TransactionToken(args.transaction); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.LIST) { - this.keys = []; - const _rtmp32287 = input.readListBegin(); - const _size2286 = _rtmp32287.size || 0; - for (let _i2288 = 0; _i2288 < _size2286; ++_i2288) { - let elem2289 = null; - elem2289 = input.readString(); - this.keys.push(elem2289); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.criteria = new data_ttypes.TCriteria(); - this.criteria.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.timestamp = input.readString(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 5: - if (ftype == Thrift.Type.STRUCT) { - this.transaction = new shared_ttypes.TransactionToken(); - this.transaction.read(input); - } else { - input.skip(ftype); - } - break; - case 6: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCriteriaTimestr_args'); - if (this.keys !== null && this.keys !== undefined) { - output.writeFieldBegin('keys', Thrift.Type.LIST, 1); - output.writeListBegin(Thrift.Type.STRING, this.keys.length); - for (let iter2290 in this.keys) { - if (this.keys.hasOwnProperty(iter2290)) { - iter2290 = this.keys[iter2290]; - output.writeString(iter2290); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.criteria !== null && this.criteria !== undefined) { - output.writeFieldBegin('criteria', Thrift.Type.STRUCT, 2); - this.criteria.write(output); - output.writeFieldEnd(); - } - if (this.timestamp !== null && this.timestamp !== undefined) { - output.writeFieldBegin('timestamp', Thrift.Type.STRING, 3); - output.writeString(this.timestamp); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.transaction !== null && this.transaction !== undefined) { - output.writeFieldBegin('transaction', Thrift.Type.STRUCT, 5); - this.transaction.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 6); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_navigateKeysCriteriaTimestr_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = Thrift.copyMap(args.success, [Thrift.copyMap, Thrift.copyList, data_ttypes.TObject]); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.MAP) { - this.success = {}; - const _rtmp32292 = input.readMapBegin(); - const _size2291 = _rtmp32292.size || 0; - for (let _i2293 = 0; _i2293 < _size2291; ++_i2293) { - let key2294 = null; - let val2295 = null; - key2294 = input.readI64(); - val2295 = {}; - const _rtmp32297 = input.readMapBegin(); - const _size2296 = _rtmp32297.size || 0; - for (let _i2298 = 0; _i2298 < _size2296; ++_i2298) { - let key2299 = null; - let val2300 = null; - key2299 = input.readString(); - val2300 = []; - const _rtmp32302 = input.readSetBegin(); - const _size2301 = _rtmp32302.size || 0; - for (let _i2303 = 0; _i2303 < _size2301; ++_i2303) { - let elem2304 = null; - elem2304 = new data_ttypes.TObject(); - elem2304.read(input); - val2300.push(elem2304); - } - input.readSetEnd(); - val2295[key2299] = val2300; - } - input.readMapEnd(); - this.success[key2294] = val2295; - } - input.readMapEnd(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_navigateKeysCriteriaTimestr_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.MAP, 0); - output.writeMapBegin(Thrift.Type.I64, Thrift.Type.MAP, Thrift.objectLength(this.success)); - for (let kiter2305 in this.success) { - if (this.success.hasOwnProperty(kiter2305)) { - let viter2306 = this.success[kiter2305]; - output.writeI64(kiter2305); - output.writeMapBegin(Thrift.Type.STRING, Thrift.Type.SET, Thrift.objectLength(viter2306)); - for (let kiter2307 in viter2306) { - if (viter2306.hasOwnProperty(kiter2307)) { - let viter2308 = viter2306[kiter2307]; - output.writeString(kiter2307); - output.writeSetBegin(Thrift.Type.STRUCT, viter2308.length); - for (let iter2309 in viter2308) { - if (viter2308.hasOwnProperty(iter2309)) { - iter2309 = viter2308[iter2309]; - iter2309.write(output); - } - } - output.writeSetEnd(); - } - } - output.writeMapEnd(); - } - } - output.writeMapEnd(); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getServerEnvironment_args = class { - constructor(args) { - this.creds = null; - this.token = null; - this.environment = null; - if (args) { - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.token !== undefined && args.token !== null) { - this.token = new shared_ttypes.TransactionToken(args.token); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.token = new shared_ttypes.TransactionToken(); - this.token.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getServerEnvironment_args'); - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.token !== null && this.token !== undefined) { - output.writeFieldBegin('token', Thrift.Type.STRUCT, 2); - this.token.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 3); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getServerEnvironment_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRING) { - this.success = input.readString(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getServerEnvironment_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRING, 0); - output.writeString(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getServerVersion_args = class { - constructor(args) { - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - if (ftype == Thrift.Type.STOP) { - break; - } - input.skip(ftype); - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getServerVersion_args'); - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_getServerVersion_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRING) { - this.success = input.readString(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_getServerVersion_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRING, 0); - output.writeString(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_time_args = class { - constructor(args) { - this.creds = null; - this.token = null; - this.environment = null; - if (args) { - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.token !== undefined && args.token !== null) { - this.token = new shared_ttypes.TransactionToken(args.token); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.token = new shared_ttypes.TransactionToken(); - this.token.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_time_args'); - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 1); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.token !== null && this.token !== undefined) { - output.writeFieldBegin('token', Thrift.Type.STRUCT, 2); - this.token.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 3); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_time_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex3 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.PermissionException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_time_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_timePhrase_args = class { - constructor(args) { - this.phrase = null; - this.creds = null; - this.token = null; - this.environment = null; - if (args) { - if (args.phrase !== undefined && args.phrase !== null) { - this.phrase = args.phrase; - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - if (args.token !== undefined && args.token !== null) { - this.token = new shared_ttypes.TransactionToken(args.token); - } - if (args.environment !== undefined && args.environment !== null) { - this.environment = args.environment; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 1: - if (ftype == Thrift.Type.STRING) { - this.phrase = input.readString(); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.token = new shared_ttypes.TransactionToken(); - this.token.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRING) { - this.environment = input.readString(); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_timePhrase_args'); - if (this.phrase !== null && this.phrase !== undefined) { - output.writeFieldBegin('phrase', Thrift.Type.STRING, 1); - output.writeString(this.phrase); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 2); - this.creds.write(output); - output.writeFieldEnd(); - } - if (this.token !== null && this.token !== undefined) { - output.writeFieldBegin('token', Thrift.Type.STRUCT, 3); - this.token.write(output); - output.writeFieldEnd(); - } - if (this.environment !== null && this.environment !== undefined) { - output.writeFieldBegin('environment', Thrift.Type.STRING, 4); - output.writeString(this.environment); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_timePhrase_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - this.ex3 = null; - this.ex4 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.TransactionException) { - this.ex2 = args; - return; - } - if (args instanceof exceptions_ttypes.ParseException) { - this.ex3 = args; - return; - } - if (args instanceof exceptions_ttypes.PermissionException) { - this.ex4 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = args.success; - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - if (args.ex3 !== undefined && args.ex3 !== null) { - this.ex3 = args.ex3; - } - if (args.ex4 !== undefined && args.ex4 !== null) { - this.ex4 = args.ex4; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.I64) { - this.success = input.readI64(); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.TransactionException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.STRUCT) { - this.ex3 = new exceptions_ttypes.ParseException(); - this.ex3.read(input); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.ex4 = new exceptions_ttypes.PermissionException(); - this.ex4.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_timePhrase_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.I64, 0); - output.writeI64(this.success); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - if (this.ex3 !== null && this.ex3 !== undefined) { - output.writeFieldBegin('ex3', Thrift.Type.STRUCT, 3); - this.ex3.write(output); - output.writeFieldEnd(); - } - if (this.ex4 !== null && this.ex4 !== undefined) { - output.writeFieldBegin('ex4', Thrift.Type.STRUCT, 4); - this.ex4.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_invokeManagement_args = class { - constructor(args) { - this.method = null; - this.params = null; - this.creds = null; - if (args) { - if (args.method !== undefined && args.method !== null) { - this.method = args.method; - } - if (args.params !== undefined && args.params !== null) { - this.params = Thrift.copyList(args.params, [complex_ttypes.ComplexTObject]); - } - if (args.creds !== undefined && args.creds !== null) { - this.creds = new shared_ttypes.AccessToken(args.creds); - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 2: - if (ftype == Thrift.Type.STRING) { - this.method = input.readString(); - } else { - input.skip(ftype); - } - break; - case 3: - if (ftype == Thrift.Type.LIST) { - this.params = []; - const _rtmp32311 = input.readListBegin(); - const _size2310 = _rtmp32311.size || 0; - for (let _i2312 = 0; _i2312 < _size2310; ++_i2312) { - let elem2313 = null; - elem2313 = new complex_ttypes.ComplexTObject(); - elem2313.read(input); - this.params.push(elem2313); - } - input.readListEnd(); - } else { - input.skip(ftype); - } - break; - case 4: - if (ftype == Thrift.Type.STRUCT) { - this.creds = new shared_ttypes.AccessToken(); - this.creds.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_invokeManagement_args'); - if (this.method !== null && this.method !== undefined) { - output.writeFieldBegin('method', Thrift.Type.STRING, 2); - output.writeString(this.method); - output.writeFieldEnd(); - } - if (this.params !== null && this.params !== undefined) { - output.writeFieldBegin('params', Thrift.Type.LIST, 3); - output.writeListBegin(Thrift.Type.STRUCT, this.params.length); - for (let iter2314 in this.params) { - if (this.params.hasOwnProperty(iter2314)) { - iter2314 = this.params[iter2314]; - iter2314.write(output); - } - } - output.writeListEnd(); - output.writeFieldEnd(); - } - if (this.creds !== null && this.creds !== undefined) { - output.writeFieldBegin('creds', Thrift.Type.STRUCT, 4); - this.creds.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseService_invokeManagement_result = class { - constructor(args) { - this.success = null; - this.ex = null; - this.ex2 = null; - if (args instanceof exceptions_ttypes.SecurityException) { - this.ex = args; - return; - } - if (args instanceof exceptions_ttypes.ManagementException) { - this.ex2 = args; - return; - } - if (args) { - if (args.success !== undefined && args.success !== null) { - this.success = new complex_ttypes.ComplexTObject(args.success); - } - if (args.ex !== undefined && args.ex !== null) { - this.ex = args.ex; - } - if (args.ex2 !== undefined && args.ex2 !== null) { - this.ex2 = args.ex2; - } - } - } - - read (input) { - input.readStructBegin(); - while (true) { - const ret = input.readFieldBegin(); - const ftype = ret.ftype; - const fid = ret.fid; - if (ftype == Thrift.Type.STOP) { - break; - } - switch (fid) { - case 0: - if (ftype == Thrift.Type.STRUCT) { - this.success = new complex_ttypes.ComplexTObject(); - this.success.read(input); - } else { - input.skip(ftype); - } - break; - case 1: - if (ftype == Thrift.Type.STRUCT) { - this.ex = new exceptions_ttypes.SecurityException(); - this.ex.read(input); - } else { - input.skip(ftype); - } - break; - case 2: - if (ftype == Thrift.Type.STRUCT) { - this.ex2 = new exceptions_ttypes.ManagementException(); - this.ex2.read(input); - } else { - input.skip(ftype); - } - break; - default: - input.skip(ftype); - } - input.readFieldEnd(); - } - input.readStructEnd(); - return; - } - - write (output) { - output.writeStructBegin('ConcourseService_invokeManagement_result'); - if (this.success !== null && this.success !== undefined) { - output.writeFieldBegin('success', Thrift.Type.STRUCT, 0); - this.success.write(output); - output.writeFieldEnd(); - } - if (this.ex !== null && this.ex !== undefined) { - output.writeFieldBegin('ex', Thrift.Type.STRUCT, 1); - this.ex.write(output); - output.writeFieldEnd(); - } - if (this.ex2 !== null && this.ex2 !== undefined) { - output.writeFieldBegin('ex2', Thrift.Type.STRUCT, 2); - this.ex2.write(output); - output.writeFieldEnd(); - } - output.writeFieldStop(); - output.writeStructEnd(); - return; - } - -}; -const ConcourseServiceClient = exports.Client = class { - constructor(output, pClass) { - this.output = output; - this.pClass = pClass; - this._seqid = 0; - this._reqs = {}; - } - seqid () { return this._seqid; } - new_seqid () { return this._seqid += 1; } - - abort (creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_abort(creds, transaction, environment); - }); - } - - send_abort (creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_abort_args(params); - try { - output.writeMessageBegin('abort', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_abort (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_abort_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - callback(null); - } - - addKeyValue (key, value, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_addKeyValue(key, value, creds, transaction, environment); - }); - } - - send_addKeyValue (key, value, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_addKeyValue_args(params); - try { - output.writeMessageBegin('addKeyValue', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_addKeyValue (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_addKeyValue_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('addKeyValue failed: unknown result'); - } - - addKeyValueRecord (key, value, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_addKeyValueRecord(key, value, record, creds, transaction, environment); - }); - } - - send_addKeyValueRecord (key, value, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_addKeyValueRecord_args(params); - try { - output.writeMessageBegin('addKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_addKeyValueRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_addKeyValueRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('addKeyValueRecord failed: unknown result'); - } - - addKeyValueRecords (key, value, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_addKeyValueRecords(key, value, records, creds, transaction, environment); - }); - } - - send_addKeyValueRecords (key, value, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_addKeyValueRecords_args(params); - try { - output.writeMessageBegin('addKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_addKeyValueRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_addKeyValueRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('addKeyValueRecords failed: unknown result'); - } - - auditRecord (record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditRecord(record, creds, transaction, environment); - }); - } - - send_auditRecord (record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditRecord_args(params); - try { - output.writeMessageBegin('auditRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditRecord failed: unknown result'); - } - - auditRecordStart (record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditRecordStart(record, start, creds, transaction, environment); - }); - } - - send_auditRecordStart (record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditRecordStart_args(params); - try { - output.writeMessageBegin('auditRecordStart', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditRecordStart (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditRecordStart_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditRecordStart failed: unknown result'); - } - - auditRecordStartstr (record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditRecordStartstr(record, start, creds, transaction, environment); - }); - } - - send_auditRecordStartstr (record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditRecordStartstr_args(params); - try { - output.writeMessageBegin('auditRecordStartstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditRecordStartstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditRecordStartstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditRecordStartstr failed: unknown result'); - } - - auditRecordStartEnd (record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditRecordStartEnd(record, start, tend, creds, transaction, environment); - }); - } - - send_auditRecordStartEnd (record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditRecordStartEnd_args(params); - try { - output.writeMessageBegin('auditRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditRecordStartEnd (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditRecordStartEnd_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditRecordStartEnd failed: unknown result'); - } - - auditRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditRecordStartstrEndstr(record, start, tend, creds, transaction, environment); - }); - } - - send_auditRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditRecordStartstrEndstr_args(params); - try { - output.writeMessageBegin('auditRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditRecordStartstrEndstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditRecordStartstrEndstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditRecordStartstrEndstr failed: unknown result'); - } - - auditKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_auditKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditKeyRecord_args(params); - try { - output.writeMessageBegin('auditKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditKeyRecord failed: unknown result'); - } - - auditKeyRecordStart (key, record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditKeyRecordStart(key, record, start, creds, transaction, environment); - }); - } - - send_auditKeyRecordStart (key, record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditKeyRecordStart_args(params); - try { - output.writeMessageBegin('auditKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditKeyRecordStart (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditKeyRecordStart_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditKeyRecordStart failed: unknown result'); - } - - auditKeyRecordStartstr (key, record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditKeyRecordStartstr(key, record, start, creds, transaction, environment); - }); - } - - send_auditKeyRecordStartstr (key, record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditKeyRecordStartstr_args(params); - try { - output.writeMessageBegin('auditKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditKeyRecordStartstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditKeyRecordStartstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditKeyRecordStartstr failed: unknown result'); - } - - auditKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); - }); - } - - send_auditKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditKeyRecordStartEnd_args(params); - try { - output.writeMessageBegin('auditKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditKeyRecordStartEnd (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditKeyRecordStartEnd_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditKeyRecordStartEnd failed: unknown result'); - } - - auditKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_auditKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); - }); - } - - send_auditKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_auditKeyRecordStartstrEndstr_args(params); - try { - output.writeMessageBegin('auditKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_auditKeyRecordStartstrEndstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_auditKeyRecordStartstrEndstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('auditKeyRecordStartstrEndstr failed: unknown result'); - } - - browseKey (key, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_browseKey(key, creds, transaction, environment); - }); - } - - send_browseKey (key, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_browseKey_args(params); - try { - output.writeMessageBegin('browseKey', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_browseKey (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_browseKey_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('browseKey failed: unknown result'); - } - - browseKeys (keys, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_browseKeys(keys, creds, transaction, environment); - }); - } - - send_browseKeys (keys, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_browseKeys_args(params); - try { - output.writeMessageBegin('browseKeys', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_browseKeys (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_browseKeys_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('browseKeys failed: unknown result'); - } - - browseKeyTime (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_browseKeyTime(key, timestamp, creds, transaction, environment); - }); - } - - send_browseKeyTime (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_browseKeyTime_args(params); - try { - output.writeMessageBegin('browseKeyTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_browseKeyTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_browseKeyTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('browseKeyTime failed: unknown result'); - } - - browseKeyTimestr (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_browseKeyTimestr(key, timestamp, creds, transaction, environment); - }); - } - - send_browseKeyTimestr (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_browseKeyTimestr_args(params); - try { - output.writeMessageBegin('browseKeyTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_browseKeyTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_browseKeyTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('browseKeyTimestr failed: unknown result'); - } - - browseKeysTime (keys, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_browseKeysTime(keys, timestamp, creds, transaction, environment); - }); - } - - send_browseKeysTime (keys, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_browseKeysTime_args(params); - try { - output.writeMessageBegin('browseKeysTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_browseKeysTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_browseKeysTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('browseKeysTime failed: unknown result'); - } - - browseKeysTimestr (keys, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_browseKeysTimestr(keys, timestamp, creds, transaction, environment); - }); - } - - send_browseKeysTimestr (keys, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_browseKeysTimestr_args(params); - try { - output.writeMessageBegin('browseKeysTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_browseKeysTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_browseKeysTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('browseKeysTimestr failed: unknown result'); - } - - chronologizeKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_chronologizeKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_chronologizeKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_chronologizeKeyRecord_args(params); - try { - output.writeMessageBegin('chronologizeKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_chronologizeKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_chronologizeKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('chronologizeKeyRecord failed: unknown result'); - } - - chronologizeKeyRecordStart (key, record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_chronologizeKeyRecordStart(key, record, start, creds, transaction, environment); - }); - } - - send_chronologizeKeyRecordStart (key, record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_chronologizeKeyRecordStart_args(params); - try { - output.writeMessageBegin('chronologizeKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_chronologizeKeyRecordStart (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_chronologizeKeyRecordStart_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('chronologizeKeyRecordStart failed: unknown result'); - } - - chronologizeKeyRecordStartstr (key, record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_chronologizeKeyRecordStartstr(key, record, start, creds, transaction, environment); - }); - } - - send_chronologizeKeyRecordStartstr (key, record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_chronologizeKeyRecordStartstr_args(params); - try { - output.writeMessageBegin('chronologizeKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_chronologizeKeyRecordStartstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_chronologizeKeyRecordStartstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('chronologizeKeyRecordStartstr failed: unknown result'); - } - - chronologizeKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_chronologizeKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); - }); - } - - send_chronologizeKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_chronologizeKeyRecordStartEnd_args(params); - try { - output.writeMessageBegin('chronologizeKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_chronologizeKeyRecordStartEnd (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_chronologizeKeyRecordStartEnd_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('chronologizeKeyRecordStartEnd failed: unknown result'); - } - - chronologizeKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_chronologizeKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); - }); - } - - send_chronologizeKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_chronologizeKeyRecordStartstrEndstr_args(params); - try { - output.writeMessageBegin('chronologizeKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_chronologizeKeyRecordStartstrEndstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('chronologizeKeyRecordStartstrEndstr failed: unknown result'); - } - - clearRecord (record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_clearRecord(record, creds, transaction, environment); - }); - } - - send_clearRecord (record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_clearRecord_args(params); - try { - output.writeMessageBegin('clearRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_clearRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_clearRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - clearRecords (records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_clearRecords(records, creds, transaction, environment); - }); - } - - send_clearRecords (records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_clearRecords_args(params); - try { - output.writeMessageBegin('clearRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_clearRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_clearRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - clearKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_clearKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_clearKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_clearKeyRecord_args(params); - try { - output.writeMessageBegin('clearKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_clearKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_clearKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - clearKeysRecord (keys, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_clearKeysRecord(keys, record, creds, transaction, environment); - }); - } - - send_clearKeysRecord (keys, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_clearKeysRecord_args(params); - try { - output.writeMessageBegin('clearKeysRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_clearKeysRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_clearKeysRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - clearKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_clearKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_clearKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_clearKeyRecords_args(params); - try { - output.writeMessageBegin('clearKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_clearKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_clearKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - clearKeysRecords (keys, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_clearKeysRecords(keys, records, creds, transaction, environment); - }); - } - - send_clearKeysRecords (keys, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_clearKeysRecords_args(params); - try { - output.writeMessageBegin('clearKeysRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_clearKeysRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_clearKeysRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - commit (creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_commit(creds, transaction, environment); - }); - } - - send_commit (creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_commit_args(params); - try { - output.writeMessageBegin('commit', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_commit (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_commit_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('commit failed: unknown result'); - } - - describe (creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describe(creds, transaction, environment); - }); - } - - send_describe (creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describe_args(params); - try { - output.writeMessageBegin('describe', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describe (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describe_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describe failed: unknown result'); - } - - describeTime (timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeTime(timestamp, creds, transaction, environment); - }); - } - - send_describeTime (timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeTime_args(params); - try { - output.writeMessageBegin('describeTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeTime failed: unknown result'); - } - - describeTimestr (timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeTimestr(timestamp, creds, transaction, environment); - }); - } - - send_describeTimestr (timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeTimestr_args(params); - try { - output.writeMessageBegin('describeTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeTimestr failed: unknown result'); - } - - describeRecord (record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeRecord(record, creds, transaction, environment); - }); - } - - send_describeRecord (record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeRecord_args(params); - try { - output.writeMessageBegin('describeRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeRecord failed: unknown result'); - } - - describeRecordTime (record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeRecordTime(record, timestamp, creds, transaction, environment); - }); - } - - send_describeRecordTime (record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeRecordTime_args(params); - try { - output.writeMessageBegin('describeRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeRecordTime failed: unknown result'); - } - - describeRecordTimestr (record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeRecordTimestr(record, timestamp, creds, transaction, environment); - }); - } - - send_describeRecordTimestr (record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeRecordTimestr_args(params); - try { - output.writeMessageBegin('describeRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeRecordTimestr failed: unknown result'); - } - - describeRecords (records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeRecords(records, creds, transaction, environment); - }); - } - - send_describeRecords (records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeRecords_args(params); - try { - output.writeMessageBegin('describeRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeRecords failed: unknown result'); - } - - describeRecordsTime (records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeRecordsTime(records, timestamp, creds, transaction, environment); - }); - } - - send_describeRecordsTime (records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeRecordsTime_args(params); - try { - output.writeMessageBegin('describeRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeRecordsTime failed: unknown result'); - } - - describeRecordsTimestr (records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_describeRecordsTimestr(records, timestamp, creds, transaction, environment); - }); - } - - send_describeRecordsTimestr (records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_describeRecordsTimestr_args(params); - try { - output.writeMessageBegin('describeRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_describeRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_describeRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('describeRecordsTimestr failed: unknown result'); - } - - diffRecordStart (record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffRecordStart(record, start, creds, transaction, environment); - }); - } - - send_diffRecordStart (record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffRecordStart_args(params); - try { - output.writeMessageBegin('diffRecordStart', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffRecordStart (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffRecordStart_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffRecordStart failed: unknown result'); - } - - diffRecordStartstr (record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffRecordStartstr(record, start, creds, transaction, environment); - }); - } - - send_diffRecordStartstr (record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffRecordStartstr_args(params); - try { - output.writeMessageBegin('diffRecordStartstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffRecordStartstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffRecordStartstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffRecordStartstr failed: unknown result'); - } - - diffRecordStartEnd (record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffRecordStartEnd(record, start, tend, creds, transaction, environment); - }); - } - - send_diffRecordStartEnd (record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffRecordStartEnd_args(params); - try { - output.writeMessageBegin('diffRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffRecordStartEnd (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffRecordStartEnd_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffRecordStartEnd failed: unknown result'); - } - - diffRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffRecordStartstrEndstr(record, start, tend, creds, transaction, environment); - }); - } - - send_diffRecordStartstrEndstr (record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffRecordStartstrEndstr_args(params); - try { - output.writeMessageBegin('diffRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffRecordStartstrEndstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffRecordStartstrEndstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffRecordStartstrEndstr failed: unknown result'); - } - - diffKeyRecordStart (key, record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyRecordStart(key, record, start, creds, transaction, environment); - }); - } - - send_diffKeyRecordStart (key, record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyRecordStart_args(params); - try { - output.writeMessageBegin('diffKeyRecordStart', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyRecordStart (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyRecordStart_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyRecordStart failed: unknown result'); - } - - diffKeyRecordStartstr (key, record, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyRecordStartstr(key, record, start, creds, transaction, environment); - }); - } - - send_diffKeyRecordStartstr (key, record, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyRecordStartstr_args(params); - try { - output.writeMessageBegin('diffKeyRecordStartstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyRecordStartstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyRecordStartstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyRecordStartstr failed: unknown result'); - } - - diffKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyRecordStartEnd(key, record, start, tend, creds, transaction, environment); - }); - } - - send_diffKeyRecordStartEnd (key, record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyRecordStartEnd_args(params); - try { - output.writeMessageBegin('diffKeyRecordStartEnd', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyRecordStartEnd (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyRecordStartEnd_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyRecordStartEnd failed: unknown result'); - } - - diffKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyRecordStartstrEndstr(key, record, start, tend, creds, transaction, environment); - }); - } - - send_diffKeyRecordStartstrEndstr (key, record, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyRecordStartstrEndstr_args(params); - try { - output.writeMessageBegin('diffKeyRecordStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyRecordStartstrEndstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyRecordStartstrEndstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyRecordStartstrEndstr failed: unknown result'); - } - - diffKeyStart (key, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyStart(key, start, creds, transaction, environment); - }); - } - - send_diffKeyStart (key, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyStart_args(params); - try { - output.writeMessageBegin('diffKeyStart', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyStart (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyStart_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyStart failed: unknown result'); - } - - diffKeyStartstr (key, start, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyStartstr(key, start, creds, transaction, environment); - }); - } - - send_diffKeyStartstr (key, start, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - start: start, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyStartstr_args(params); - try { - output.writeMessageBegin('diffKeyStartstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyStartstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyStartstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyStartstr failed: unknown result'); - } - - diffKeyStartEnd (key, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyStartEnd(key, start, tend, creds, transaction, environment); - }); - } - - send_diffKeyStartEnd (key, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyStartEnd_args(params); - try { - output.writeMessageBegin('diffKeyStartEnd', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyStartEnd (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyStartEnd_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyStartEnd failed: unknown result'); - } - - diffKeyStartstrEndstr (key, start, tend, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_diffKeyStartstrEndstr(key, start, tend, creds, transaction, environment); - }); - } - - send_diffKeyStartstrEndstr (key, start, tend, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - start: start, - tend: tend, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_diffKeyStartstrEndstr_args(params); - try { - output.writeMessageBegin('diffKeyStartstrEndstr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_diffKeyStartstrEndstr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_diffKeyStartstrEndstr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('diffKeyStartstrEndstr failed: unknown result'); - } - - invokePlugin (id, method, params, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_invokePlugin(id, method, params, creds, transaction, environment); - }); - } - - send_invokePlugin (id, method, params, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - id: id, - method: method, - params: params, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_invokePlugin_args(params); - try { - output.writeMessageBegin('invokePlugin', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_invokePlugin (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_invokePlugin_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('invokePlugin failed: unknown result'); - } - - login (username, password, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_login(username, password, environment); - }); - } - - send_login (username, password, environment) { - const output = new this.pClass(this.output); - const params = { - username: username, - password: password, - environment: environment - }; - const args = new ConcourseService_login_args(params); - try { - output.writeMessageBegin('login', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_login (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_login_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('login failed: unknown result'); - } - - logout (token, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_logout(token, environment); - }); - } - - send_logout (token, environment) { - const output = new this.pClass(this.output); - const params = { - token: token, - environment: environment - }; - const args = new ConcourseService_logout_args(params); - try { - output.writeMessageBegin('logout', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_logout (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_logout_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - callback(null); - } - - stage (token, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_stage(token, environment); - }); - } - - send_stage (token, environment) { - const output = new this.pClass(this.output); - const params = { - token: token, - environment: environment - }; - const args = new ConcourseService_stage_args(params); - try { - output.writeMessageBegin('stage', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_stage (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_stage_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('stage failed: unknown result'); - } - - insertJson (json, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_insertJson(json, creds, transaction, environment); - }); - } - - send_insertJson (json, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - json: json, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_insertJson_args(params); - try { - output.writeMessageBegin('insertJson', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_insertJson (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_insertJson_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.ex5) { - return callback(result.ex5); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('insertJson failed: unknown result'); - } - - insertJsonRecord (json, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_insertJsonRecord(json, record, creds, transaction, environment); - }); - } - - send_insertJsonRecord (json, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - json: json, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_insertJsonRecord_args(params); - try { - output.writeMessageBegin('insertJsonRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_insertJsonRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_insertJsonRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.ex5) { - return callback(result.ex5); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('insertJsonRecord failed: unknown result'); - } - - insertJsonRecords (json, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_insertJsonRecords(json, records, creds, transaction, environment); - }); - } - - send_insertJsonRecords (json, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - json: json, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_insertJsonRecords_args(params); - try { - output.writeMessageBegin('insertJsonRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_insertJsonRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_insertJsonRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.ex5) { - return callback(result.ex5); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('insertJsonRecords failed: unknown result'); - } - - removeKeyValueRecord (key, value, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_removeKeyValueRecord(key, value, record, creds, transaction, environment); - }); - } - - send_removeKeyValueRecord (key, value, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_removeKeyValueRecord_args(params); - try { - output.writeMessageBegin('removeKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_removeKeyValueRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_removeKeyValueRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('removeKeyValueRecord failed: unknown result'); - } - - removeKeyValueRecords (key, value, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_removeKeyValueRecords(key, value, records, creds, transaction, environment); - }); - } - - send_removeKeyValueRecords (key, value, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_removeKeyValueRecords_args(params); - try { - output.writeMessageBegin('removeKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_removeKeyValueRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_removeKeyValueRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('removeKeyValueRecords failed: unknown result'); - } - - setKeyValueRecord (key, value, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_setKeyValueRecord(key, value, record, creds, transaction, environment); - }); - } - - send_setKeyValueRecord (key, value, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_setKeyValueRecord_args(params); - try { - output.writeMessageBegin('setKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_setKeyValueRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_setKeyValueRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - setKeyValue (key, value, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_setKeyValue(key, value, creds, transaction, environment); - }); - } - - send_setKeyValue (key, value, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_setKeyValue_args(params); - try { - output.writeMessageBegin('setKeyValue', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_setKeyValue (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_setKeyValue_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('setKeyValue failed: unknown result'); - } - - setKeyValueRecords (key, value, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_setKeyValueRecords(key, value, records, creds, transaction, environment); - }); - } - - send_setKeyValueRecords (key, value, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_setKeyValueRecords_args(params); - try { - output.writeMessageBegin('setKeyValueRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_setKeyValueRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_setKeyValueRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - reconcileKeyRecordValues (key, record, values, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_reconcileKeyRecordValues(key, record, values, creds, transaction, environment); - }); - } - - send_reconcileKeyRecordValues (key, record, values, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - values: values, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_reconcileKeyRecordValues_args(params); - try { - output.writeMessageBegin('reconcileKeyRecordValues', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_reconcileKeyRecordValues (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_reconcileKeyRecordValues_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - inventory (creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_inventory(creds, transaction, environment); - }); - } - - send_inventory (creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_inventory_args(params); - try { - output.writeMessageBegin('inventory', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_inventory (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_inventory_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('inventory failed: unknown result'); - } - - selectRecord (record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectRecord(record, creds, transaction, environment); - }); - } - - send_selectRecord (record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectRecord_args(params); - try { - output.writeMessageBegin('selectRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectRecord failed: unknown result'); - } - - selectRecords (records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectRecords(records, creds, transaction, environment); - }); - } - - send_selectRecords (records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectRecords_args(params); - try { - output.writeMessageBegin('selectRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectRecords failed: unknown result'); - } - - selectRecordTime (record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectRecordTime(record, timestamp, creds, transaction, environment); - }); - } - - send_selectRecordTime (record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectRecordTime_args(params); - try { - output.writeMessageBegin('selectRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectRecordTime failed: unknown result'); - } - - selectRecordTimestr (record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectRecordTimestr(record, timestamp, creds, transaction, environment); - }); - } - - send_selectRecordTimestr (record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectRecordTimestr_args(params); - try { - output.writeMessageBegin('selectRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectRecordTimestr failed: unknown result'); - } - - selectRecordsTime (records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectRecordsTime(records, timestamp, creds, transaction, environment); - }); - } - - send_selectRecordsTime (records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectRecordsTime_args(params); - try { - output.writeMessageBegin('selectRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectRecordsTime failed: unknown result'); - } - - selectRecordsTimestr (records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectRecordsTimestr(records, timestamp, creds, transaction, environment); - }); - } - - send_selectRecordsTimestr (records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectRecordsTimestr_args(params); - try { - output.writeMessageBegin('selectRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectRecordsTimestr failed: unknown result'); - } - - selectKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_selectKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyRecord_args(params); - try { - output.writeMessageBegin('selectKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyRecord failed: unknown result'); - } - - selectKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyRecordTime_args(params); - try { - output.writeMessageBegin('selectKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyRecordTime failed: unknown result'); - } - - selectKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('selectKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyRecordTimestr failed: unknown result'); - } - - selectKeysRecord (keys, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysRecord(keys, record, creds, transaction, environment); - }); - } - - send_selectKeysRecord (keys, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysRecord_args(params); - try { - output.writeMessageBegin('selectKeysRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysRecord failed: unknown result'); - } - - selectKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysRecordTime(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysRecordTime_args(params); - try { - output.writeMessageBegin('selectKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysRecordTime failed: unknown result'); - } - - selectKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysRecordTimestr_args(params); - try { - output.writeMessageBegin('selectKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysRecordTimestr failed: unknown result'); - } - - selectKeysRecords (keys, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysRecords(keys, records, creds, transaction, environment); - }); - } - - send_selectKeysRecords (keys, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysRecords_args(params); - try { - output.writeMessageBegin('selectKeysRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysRecords failed: unknown result'); - } - - selectKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_selectKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyRecords_args(params); - try { - output.writeMessageBegin('selectKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyRecords failed: unknown result'); - } - - selectKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyRecordsTime_args(params); - try { - output.writeMessageBegin('selectKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyRecordsTime failed: unknown result'); - } - - selectKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('selectKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyRecordsTimestr failed: unknown result'); - } - - selectKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysRecordsTime_args(params); - try { - output.writeMessageBegin('selectKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysRecordsTime failed: unknown result'); - } - - selectKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysRecordsTimestr_args(params); - try { - output.writeMessageBegin('selectKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysRecordsTimestr failed: unknown result'); - } - - selectCriteria (criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectCriteria(criteria, creds, transaction, environment); - }); - } - - send_selectCriteria (criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectCriteria_args(params); - try { - output.writeMessageBegin('selectCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectCriteria failed: unknown result'); - } - - selectCcl (ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectCcl(ccl, creds, transaction, environment); - }); - } - - send_selectCcl (ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectCcl_args(params); - try { - output.writeMessageBegin('selectCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectCcl failed: unknown result'); - } - - selectCriteriaTime (criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectCriteriaTime(criteria, timestamp, creds, transaction, environment); - }); - } - - send_selectCriteriaTime (criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectCriteriaTime_args(params); - try { - output.writeMessageBegin('selectCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectCriteriaTime failed: unknown result'); - } - - selectCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectCriteriaTimestr(criteria, timestamp, creds, transaction, environment); - }); - } - - send_selectCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectCriteriaTimestr_args(params); - try { - output.writeMessageBegin('selectCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectCriteriaTimestr failed: unknown result'); - } - - selectCclTime (ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectCclTime(ccl, timestamp, creds, transaction, environment); - }); - } - - send_selectCclTime (ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectCclTime_args(params); - try { - output.writeMessageBegin('selectCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectCclTime failed: unknown result'); - } - - selectCclTimestr (ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectCclTimestr(ccl, timestamp, creds, transaction, environment); - }); - } - - send_selectCclTimestr (ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectCclTimestr_args(params); - try { - output.writeMessageBegin('selectCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectCclTimestr failed: unknown result'); - } - - selectKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_selectKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyCriteria_args(params); - try { - output.writeMessageBegin('selectKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyCriteria failed: unknown result'); - } - - selectKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_selectKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyCcl_args(params); - try { - output.writeMessageBegin('selectKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyCcl failed: unknown result'); - } - - selectKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('selectKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyCriteriaTime failed: unknown result'); - } - - selectKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('selectKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyCriteriaTimestr failed: unknown result'); - } - - selectKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyCclTime_args(params); - try { - output.writeMessageBegin('selectKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyCclTime failed: unknown result'); - } - - selectKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_selectKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeyCclTimestr_args(params); - try { - output.writeMessageBegin('selectKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeyCclTimestr failed: unknown result'); - } - - selectKeysCriteria (keys, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysCriteria(keys, criteria, creds, transaction, environment); - }); - } - - send_selectKeysCriteria (keys, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysCriteria_args(params); - try { - output.writeMessageBegin('selectKeysCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysCriteria failed: unknown result'); - } - - selectKeysCcl (keys, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysCcl(keys, ccl, creds, transaction, environment); - }); - } - - send_selectKeysCcl (keys, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysCcl_args(params); - try { - output.writeMessageBegin('selectKeysCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysCcl failed: unknown result'); - } - - selectKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysCriteriaTime_args(params); - try { - output.writeMessageBegin('selectKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysCriteriaTime failed: unknown result'); - } - - selectKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysCriteriaTimestr_args(params); - try { - output.writeMessageBegin('selectKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysCriteriaTimestr failed: unknown result'); - } - - selectKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysCclTime_args(params); - try { - output.writeMessageBegin('selectKeysCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysCclTime failed: unknown result'); - } - - selectKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_selectKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); - }); - } - - send_selectKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_selectKeysCclTimestr_args(params); - try { - output.writeMessageBegin('selectKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_selectKeysCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_selectKeysCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('selectKeysCclTimestr failed: unknown result'); - } - - getKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_getKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyRecord_args(params); - try { - output.writeMessageBegin('getKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyRecord failed: unknown result'); - } - - getKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_getKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyRecordTime_args(params); - try { - output.writeMessageBegin('getKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyRecordTime failed: unknown result'); - } - - getKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_getKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('getKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyRecordTimestr failed: unknown result'); - } - - getKeysRecord (keys, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysRecord(keys, record, creds, transaction, environment); - }); - } - - send_getKeysRecord (keys, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysRecord_args(params); - try { - output.writeMessageBegin('getKeysRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysRecord failed: unknown result'); - } - - getKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysRecordTime(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_getKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysRecordTime_args(params); - try { - output.writeMessageBegin('getKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysRecordTime failed: unknown result'); - } - - getKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_getKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysRecordTimestr_args(params); - try { - output.writeMessageBegin('getKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysRecordTimestr failed: unknown result'); - } - - getKeysRecords (keys, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysRecords(keys, records, creds, transaction, environment); - }); - } - - send_getKeysRecords (keys, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysRecords_args(params); - try { - output.writeMessageBegin('getKeysRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysRecords failed: unknown result'); - } - - getKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_getKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyRecords_args(params); - try { - output.writeMessageBegin('getKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyRecords failed: unknown result'); - } - - getKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_getKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyRecordsTime_args(params); - try { - output.writeMessageBegin('getKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyRecordsTime failed: unknown result'); - } - - getKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_getKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('getKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyRecordsTimestr failed: unknown result'); - } - - getKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_getKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysRecordsTime_args(params); - try { - output.writeMessageBegin('getKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysRecordsTime failed: unknown result'); - } - - getKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_getKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysRecordsTimestr_args(params); - try { - output.writeMessageBegin('getKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysRecordsTimestr failed: unknown result'); - } - - getKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_getKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyCriteria_args(params); - try { - output.writeMessageBegin('getKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyCriteria failed: unknown result'); - } - - getCriteria (criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getCriteria(criteria, creds, transaction, environment); - }); - } - - send_getCriteria (criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getCriteria_args(params); - try { - output.writeMessageBegin('getCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getCriteria failed: unknown result'); - } - - getCcl (ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getCcl(ccl, creds, transaction, environment); - }); - } - - send_getCcl (ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getCcl_args(params); - try { - output.writeMessageBegin('getCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getCcl failed: unknown result'); - } - - getCriteriaTime (criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getCriteriaTime(criteria, timestamp, creds, transaction, environment); - }); - } - - send_getCriteriaTime (criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getCriteriaTime_args(params); - try { - output.writeMessageBegin('getCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getCriteriaTime failed: unknown result'); - } - - getCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getCriteriaTimestr(criteria, timestamp, creds, transaction, environment); - }); - } - - send_getCriteriaTimestr (criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getCriteriaTimestr_args(params); - try { - output.writeMessageBegin('getCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getCriteriaTimestr failed: unknown result'); - } - - getCclTime (ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getCclTime(ccl, timestamp, creds, transaction, environment); - }); - } - - send_getCclTime (ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getCclTime_args(params); - try { - output.writeMessageBegin('getCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getCclTime failed: unknown result'); - } - - getCclTimestr (ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getCclTimestr(ccl, timestamp, creds, transaction, environment); - }); - } - - send_getCclTimestr (ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getCclTimestr_args(params); - try { - output.writeMessageBegin('getCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getCclTimestr failed: unknown result'); - } - - getKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_getKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyCcl_args(params); - try { - output.writeMessageBegin('getKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyCcl failed: unknown result'); - } - - getKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_getKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('getKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyCriteriaTime failed: unknown result'); - } - - getKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_getKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('getKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyCriteriaTimestr failed: unknown result'); - } - - getKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_getKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyCclTime_args(params); - try { - output.writeMessageBegin('getKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyCclTime failed: unknown result'); - } - - getKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_getKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeyCclTimestr_args(params); - try { - output.writeMessageBegin('getKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeyCclTimestr failed: unknown result'); - } - - getKeysCriteria (keys, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysCriteria(keys, criteria, creds, transaction, environment); - }); - } - - send_getKeysCriteria (keys, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysCriteria_args(params); - try { - output.writeMessageBegin('getKeysCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysCriteria failed: unknown result'); - } - - getKeysCcl (keys, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysCcl(keys, ccl, creds, transaction, environment); - }); - } - - send_getKeysCcl (keys, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysCcl_args(params); - try { - output.writeMessageBegin('getKeysCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysCcl failed: unknown result'); - } - - getKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); - }); - } - - send_getKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysCriteriaTime_args(params); - try { - output.writeMessageBegin('getKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysCriteriaTime failed: unknown result'); - } - - getKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); - }); - } - - send_getKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysCriteriaTimestr_args(params); - try { - output.writeMessageBegin('getKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysCriteriaTimestr failed: unknown result'); - } - - getKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); - }); - } - - send_getKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysCclTime_args(params); - try { - output.writeMessageBegin('getKeysCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysCclTime failed: unknown result'); - } - - getKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); - }); - } - - send_getKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_getKeysCclTimestr_args(params); - try { - output.writeMessageBegin('getKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getKeysCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getKeysCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getKeysCclTimestr failed: unknown result'); - } - - verifyKeyValueRecord (key, value, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_verifyKeyValueRecord(key, value, record, creds, transaction, environment); - }); - } - - send_verifyKeyValueRecord (key, value, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_verifyKeyValueRecord_args(params); - try { - output.writeMessageBegin('verifyKeyValueRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_verifyKeyValueRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_verifyKeyValueRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('verifyKeyValueRecord failed: unknown result'); - } - - verifyKeyValueRecordTime (key, value, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_verifyKeyValueRecordTime(key, value, record, timestamp, creds, transaction, environment); - }); - } - - send_verifyKeyValueRecordTime (key, value, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_verifyKeyValueRecordTime_args(params); - try { - output.writeMessageBegin('verifyKeyValueRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_verifyKeyValueRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_verifyKeyValueRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('verifyKeyValueRecordTime failed: unknown result'); - } - - verifyKeyValueRecordTimestr (key, value, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_verifyKeyValueRecordTimestr(key, value, record, timestamp, creds, transaction, environment); - }); - } - - send_verifyKeyValueRecordTimestr (key, value, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_verifyKeyValueRecordTimestr_args(params); - try { - output.writeMessageBegin('verifyKeyValueRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_verifyKeyValueRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_verifyKeyValueRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('verifyKeyValueRecordTimestr failed: unknown result'); - } - - jsonifyRecords (records, identifier, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_jsonifyRecords(records, identifier, creds, transaction, environment); - }); - } - - send_jsonifyRecords (records, identifier, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - identifier: identifier, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_jsonifyRecords_args(params); - try { - output.writeMessageBegin('jsonifyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_jsonifyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_jsonifyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('jsonifyRecords failed: unknown result'); - } - - jsonifyRecordsTime (records, timestamp, identifier, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_jsonifyRecordsTime(records, timestamp, identifier, creds, transaction, environment); - }); - } - - send_jsonifyRecordsTime (records, timestamp, identifier, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - timestamp: timestamp, - identifier: identifier, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_jsonifyRecordsTime_args(params); - try { - output.writeMessageBegin('jsonifyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_jsonifyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_jsonifyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('jsonifyRecordsTime failed: unknown result'); - } - - jsonifyRecordsTimestr (records, timestamp, identifier, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_jsonifyRecordsTimestr(records, timestamp, identifier, creds, transaction, environment); - }); - } - - send_jsonifyRecordsTimestr (records, timestamp, identifier, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - timestamp: timestamp, - identifier: identifier, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_jsonifyRecordsTimestr_args(params); - try { - output.writeMessageBegin('jsonifyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_jsonifyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_jsonifyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('jsonifyRecordsTimestr failed: unknown result'); - } - - findCriteria (criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findCriteria(criteria, creds, transaction, environment); - }); - } - - send_findCriteria (criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findCriteria_args(params); - try { - output.writeMessageBegin('findCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findCriteria failed: unknown result'); - } - - findCcl (ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findCcl(ccl, creds, transaction, environment); - }); - } - - send_findCcl (ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findCcl_args(params); - try { - output.writeMessageBegin('findCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findCcl failed: unknown result'); - } - - findKeyOperatorValues (key, operator, values, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findKeyOperatorValues(key, operator, values, creds, transaction, environment); - }); - } - - send_findKeyOperatorValues (key, operator, values, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - operator: operator, - values: values, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findKeyOperatorValues_args(params); - try { - output.writeMessageBegin('findKeyOperatorValues', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findKeyOperatorValues (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findKeyOperatorValues_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findKeyOperatorValues failed: unknown result'); - } - - findKeyOperatorValuesTime (key, operator, values, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findKeyOperatorValuesTime(key, operator, values, timestamp, creds, transaction, environment); - }); - } - - send_findKeyOperatorValuesTime (key, operator, values, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - operator: operator, - values: values, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findKeyOperatorValuesTime_args(params); - try { - output.writeMessageBegin('findKeyOperatorValuesTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findKeyOperatorValuesTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findKeyOperatorValuesTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findKeyOperatorValuesTime failed: unknown result'); - } - - findKeyOperatorValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findKeyOperatorValuesTimestr(key, operator, values, timestamp, creds, transaction, environment); - }); - } - - send_findKeyOperatorValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - operator: operator, - values: values, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findKeyOperatorValuesTimestr_args(params); - try { - output.writeMessageBegin('findKeyOperatorValuesTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findKeyOperatorValuesTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findKeyOperatorValuesTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findKeyOperatorValuesTimestr failed: unknown result'); - } - - findKeyOperatorstrValues (key, operator, values, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findKeyOperatorstrValues(key, operator, values, creds, transaction, environment); - }); - } - - send_findKeyOperatorstrValues (key, operator, values, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - operator: operator, - values: values, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findKeyOperatorstrValues_args(params); - try { - output.writeMessageBegin('findKeyOperatorstrValues', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findKeyOperatorstrValues (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findKeyOperatorstrValues_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findKeyOperatorstrValues failed: unknown result'); - } - - findKeyOperatorstrValuesTime (key, operator, values, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findKeyOperatorstrValuesTime(key, operator, values, timestamp, creds, transaction, environment); - }); - } - - send_findKeyOperatorstrValuesTime (key, operator, values, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - operator: operator, - values: values, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findKeyOperatorstrValuesTime_args(params); - try { - output.writeMessageBegin('findKeyOperatorstrValuesTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findKeyOperatorstrValuesTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findKeyOperatorstrValuesTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findKeyOperatorstrValuesTime failed: unknown result'); - } - - findKeyOperatorstrValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findKeyOperatorstrValuesTimestr(key, operator, values, timestamp, creds, transaction, environment); - }); - } - - send_findKeyOperatorstrValuesTimestr (key, operator, values, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - operator: operator, - values: values, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findKeyOperatorstrValuesTimestr_args(params); - try { - output.writeMessageBegin('findKeyOperatorstrValuesTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findKeyOperatorstrValuesTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findKeyOperatorstrValuesTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findKeyOperatorstrValuesTimestr failed: unknown result'); - } - - search (key, query, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_search(key, query, creds, transaction, environment); - }); - } - - send_search (key, query, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - query: query, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_search_args(params); - try { - output.writeMessageBegin('search', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_search (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_search_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('search failed: unknown result'); - } - - revertKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_revertKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeysRecordsTime_args(params); - try { - output.writeMessageBegin('revertKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeysRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeysRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - revertKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_revertKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeysRecordsTimestr_args(params); - try { - output.writeMessageBegin('revertKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeysRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeysRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - revertKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeysRecordTime(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_revertKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeysRecordTime_args(params); - try { - output.writeMessageBegin('revertKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeysRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeysRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - revertKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_revertKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeysRecordTimestr_args(params); - try { - output.writeMessageBegin('revertKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeysRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeysRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - revertKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_revertKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeyRecordsTime_args(params); - try { - output.writeMessageBegin('revertKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - revertKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_revertKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('revertKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - revertKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_revertKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeyRecordTime_args(params); - try { - output.writeMessageBegin('revertKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - callback(null); - } - - revertKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_revertKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_revertKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_revertKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('revertKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_revertKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_revertKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - pingRecords (records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_pingRecords(records, creds, transaction, environment); - }); - } - - send_pingRecords (records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_pingRecords_args(params); - try { - output.writeMessageBegin('pingRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_pingRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_pingRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('pingRecords failed: unknown result'); - } - - pingRecord (record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_pingRecord(record, creds, transaction, environment); - }); - } - - send_pingRecord (record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_pingRecord_args(params); - try { - output.writeMessageBegin('pingRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_pingRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_pingRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('pingRecord failed: unknown result'); - } - - verifyAndSwap (key, expected, record, replacement, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_verifyAndSwap(key, expected, record, replacement, creds, transaction, environment); - }); - } - - send_verifyAndSwap (key, expected, record, replacement, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - expected: expected, - record: record, - replacement: replacement, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_verifyAndSwap_args(params); - try { - output.writeMessageBegin('verifyAndSwap', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_verifyAndSwap (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_verifyAndSwap_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('verifyAndSwap failed: unknown result'); - } - - verifyOrSet (key, value, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_verifyOrSet(key, value, record, creds, transaction, environment); - }); - } - - send_verifyOrSet (key, value, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_verifyOrSet_args(params); - try { - output.writeMessageBegin('verifyOrSet', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_verifyOrSet (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_verifyOrSet_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - callback(null); - } - - findOrAddKeyValue (key, value, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findOrAddKeyValue(key, value, creds, transaction, environment); - }); - } - - send_findOrAddKeyValue (key, value, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - value: value, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findOrAddKeyValue_args(params); - try { - output.writeMessageBegin('findOrAddKeyValue', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findOrAddKeyValue (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findOrAddKeyValue_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.ex5) { - return callback(result.ex5); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findOrAddKeyValue failed: unknown result'); - } - - findOrInsertCriteriaJson (criteria, json, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findOrInsertCriteriaJson(criteria, json, creds, transaction, environment); - }); - } - - send_findOrInsertCriteriaJson (criteria, json, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - criteria: criteria, - json: json, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findOrInsertCriteriaJson_args(params); - try { - output.writeMessageBegin('findOrInsertCriteriaJson', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findOrInsertCriteriaJson (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findOrInsertCriteriaJson_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findOrInsertCriteriaJson failed: unknown result'); - } - - findOrInsertCclJson (ccl, json, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_findOrInsertCclJson(ccl, json, creds, transaction, environment); - }); - } - - send_findOrInsertCclJson (ccl, json, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - ccl: ccl, - json: json, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_findOrInsertCclJson_args(params); - try { - output.writeMessageBegin('findOrInsertCclJson', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_findOrInsertCclJson (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_findOrInsertCclJson_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.ex5) { - return callback(result.ex5); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('findOrInsertCclJson failed: unknown result'); - } - - sumKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_sumKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyRecord_args(params); - try { - output.writeMessageBegin('sumKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyRecord failed: unknown result'); - } - - sumKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyRecordTime_args(params); - try { - output.writeMessageBegin('sumKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyRecordTime failed: unknown result'); - } - - sumKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('sumKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyRecordTimestr failed: unknown result'); - } - - sumKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_sumKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyRecords_args(params); - try { - output.writeMessageBegin('sumKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyRecords failed: unknown result'); - } - - sumKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyRecordsTime_args(params); - try { - output.writeMessageBegin('sumKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyRecordsTime failed: unknown result'); - } - - sumKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('sumKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyRecordsTimestr failed: unknown result'); - } - - sumKey (key, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKey(key, creds, transaction, environment); - }); - } - - send_sumKey (key, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKey_args(params); - try { - output.writeMessageBegin('sumKey', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKey (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKey_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKey failed: unknown result'); - } - - sumKeyTime (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyTime(key, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyTime (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyTime_args(params); - try { - output.writeMessageBegin('sumKeyTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyTime failed: unknown result'); - } - - sumKeyTimestr (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyTimestr(key, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyTimestr (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyTimestr_args(params); - try { - output.writeMessageBegin('sumKeyTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyTimestr failed: unknown result'); - } - - sumKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_sumKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyCriteria_args(params); - try { - output.writeMessageBegin('sumKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyCriteria failed: unknown result'); - } - - sumKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('sumKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyCriteriaTime failed: unknown result'); - } - - sumKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('sumKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyCriteriaTimestr failed: unknown result'); - } - - sumKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_sumKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyCcl_args(params); - try { - output.writeMessageBegin('sumKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyCcl failed: unknown result'); - } - - sumKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyCclTime_args(params); - try { - output.writeMessageBegin('sumKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyCclTime failed: unknown result'); - } - - sumKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_sumKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_sumKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_sumKeyCclTimestr_args(params); - try { - output.writeMessageBegin('sumKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_sumKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_sumKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('sumKeyCclTimestr failed: unknown result'); - } - - averageKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_averageKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyRecord_args(params); - try { - output.writeMessageBegin('averageKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyRecord failed: unknown result'); - } - - averageKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyRecordTime_args(params); - try { - output.writeMessageBegin('averageKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyRecordTime failed: unknown result'); - } - - averageKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('averageKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyRecordTimestr failed: unknown result'); - } - - averageKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_averageKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyRecords_args(params); - try { - output.writeMessageBegin('averageKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyRecords failed: unknown result'); - } - - averageKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyRecordsTime_args(params); - try { - output.writeMessageBegin('averageKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyRecordsTime failed: unknown result'); - } - - averageKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('averageKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyRecordsTimestr failed: unknown result'); - } - - averageKey (key, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKey(key, creds, transaction, environment); - }); - } - - send_averageKey (key, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKey_args(params); - try { - output.writeMessageBegin('averageKey', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKey (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKey_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKey failed: unknown result'); - } - - averageKeyTime (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyTime(key, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyTime (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyTime_args(params); - try { - output.writeMessageBegin('averageKeyTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyTime failed: unknown result'); - } - - averageKeyTimestr (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyTimestr(key, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyTimestr (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyTimestr_args(params); - try { - output.writeMessageBegin('averageKeyTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyTimestr failed: unknown result'); - } - - averageKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_averageKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyCriteria_args(params); - try { - output.writeMessageBegin('averageKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyCriteria failed: unknown result'); - } - - averageKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('averageKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyCriteriaTime failed: unknown result'); - } - - averageKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('averageKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyCriteriaTimestr failed: unknown result'); - } - - averageKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_averageKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyCcl_args(params); - try { - output.writeMessageBegin('averageKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyCcl failed: unknown result'); - } - - averageKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyCclTime_args(params); - try { - output.writeMessageBegin('averageKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyCclTime failed: unknown result'); - } - - averageKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_averageKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_averageKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_averageKeyCclTimestr_args(params); - try { - output.writeMessageBegin('averageKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_averageKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_averageKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('averageKeyCclTimestr failed: unknown result'); - } - - countKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_countKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyRecord_args(params); - try { - output.writeMessageBegin('countKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyRecord failed: unknown result'); - } - - countKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_countKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyRecordTime_args(params); - try { - output.writeMessageBegin('countKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyRecordTime failed: unknown result'); - } - - countKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_countKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('countKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyRecordTimestr failed: unknown result'); - } - - countKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_countKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyRecords_args(params); - try { - output.writeMessageBegin('countKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyRecords failed: unknown result'); - } - - countKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_countKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyRecordsTime_args(params); - try { - output.writeMessageBegin('countKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyRecordsTime failed: unknown result'); - } - - countKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_countKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('countKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyRecordsTimestr failed: unknown result'); - } - - countKey (key, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKey(key, creds, transaction, environment); - }); - } - - send_countKey (key, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKey_args(params); - try { - output.writeMessageBegin('countKey', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKey (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKey_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKey failed: unknown result'); - } - - countKeyTime (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyTime(key, timestamp, creds, transaction, environment); - }); - } - - send_countKeyTime (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyTime_args(params); - try { - output.writeMessageBegin('countKeyTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyTime failed: unknown result'); - } - - countKeyTimestr (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyTimestr(key, timestamp, creds, transaction, environment); - }); - } - - send_countKeyTimestr (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyTimestr_args(params); - try { - output.writeMessageBegin('countKeyTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyTimestr failed: unknown result'); - } - - countKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_countKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyCriteria_args(params); - try { - output.writeMessageBegin('countKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyCriteria failed: unknown result'); - } - - countKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_countKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('countKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyCriteriaTime failed: unknown result'); - } - - countKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_countKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('countKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyCriteriaTimestr failed: unknown result'); - } - - countKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_countKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyCcl_args(params); - try { - output.writeMessageBegin('countKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyCcl failed: unknown result'); - } - - countKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_countKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyCclTime_args(params); - try { - output.writeMessageBegin('countKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyCclTime failed: unknown result'); - } - - countKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_countKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_countKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_countKeyCclTimestr_args(params); - try { - output.writeMessageBegin('countKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_countKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_countKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('countKeyCclTimestr failed: unknown result'); - } - - maxKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_maxKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyRecord_args(params); - try { - output.writeMessageBegin('maxKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyRecord failed: unknown result'); - } - - maxKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyRecordTime_args(params); - try { - output.writeMessageBegin('maxKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyRecordTime failed: unknown result'); - } - - maxKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('maxKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyRecordTimestr failed: unknown result'); - } - - maxKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_maxKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyRecords_args(params); - try { - output.writeMessageBegin('maxKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyRecords failed: unknown result'); - } - - maxKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyRecordsTime_args(params); - try { - output.writeMessageBegin('maxKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyRecordsTime failed: unknown result'); - } - - maxKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('maxKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyRecordsTimestr failed: unknown result'); - } - - maxKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_maxKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyCriteria_args(params); - try { - output.writeMessageBegin('maxKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyCriteria failed: unknown result'); - } - - maxKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('maxKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyCriteriaTime failed: unknown result'); - } - - maxKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('maxKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyCriteriaTimestr failed: unknown result'); - } - - maxKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_maxKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyCcl_args(params); - try { - output.writeMessageBegin('maxKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyCcl failed: unknown result'); - } - - maxKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyCclTime_args(params); - try { - output.writeMessageBegin('maxKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyCclTime failed: unknown result'); - } - - maxKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyCclTimestr_args(params); - try { - output.writeMessageBegin('maxKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyCclTimestr failed: unknown result'); - } - - maxKey (key, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKey(key, creds, transaction, environment); - }); - } - - send_maxKey (key, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKey_args(params); - try { - output.writeMessageBegin('maxKey', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKey (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKey_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKey failed: unknown result'); - } - - maxKeyTime (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyTime(key, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyTime (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyTime_args(params); - try { - output.writeMessageBegin('maxKeyTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyTime failed: unknown result'); - } - - maxKeyTimestr (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_maxKeyTimestr(key, timestamp, creds, transaction, environment); - }); - } - - send_maxKeyTimestr (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_maxKeyTimestr_args(params); - try { - output.writeMessageBegin('maxKeyTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_maxKeyTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_maxKeyTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('maxKeyTimestr failed: unknown result'); - } - - minKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_minKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyRecord_args(params); - try { - output.writeMessageBegin('minKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyRecord failed: unknown result'); - } - - minKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_minKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyRecordTime_args(params); - try { - output.writeMessageBegin('minKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyRecordTime failed: unknown result'); - } - - minKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_minKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('minKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyRecordTimestr failed: unknown result'); - } - - minKey (key, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKey(key, creds, transaction, environment); - }); - } - - send_minKey (key, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKey_args(params); - try { - output.writeMessageBegin('minKey', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKey (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKey_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKey failed: unknown result'); - } - - minKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_minKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyRecordsTime_args(params); - try { - output.writeMessageBegin('minKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyRecordsTime failed: unknown result'); - } - - minKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_minKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('minKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyRecordsTimestr failed: unknown result'); - } - - minKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_minKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyCriteria_args(params); - try { - output.writeMessageBegin('minKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyCriteria failed: unknown result'); - } - - minKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_minKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('minKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyCriteriaTime failed: unknown result'); - } - - minKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_minKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('minKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyCriteriaTimestr failed: unknown result'); - } - - minKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_minKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyCcl_args(params); - try { - output.writeMessageBegin('minKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyCcl failed: unknown result'); - } - - minKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_minKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyCclTime_args(params); - try { - output.writeMessageBegin('minKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyCclTime failed: unknown result'); - } - - minKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_minKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyCclTimestr_args(params); - try { - output.writeMessageBegin('minKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyCclTimestr failed: unknown result'); - } - - minKeyTime (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyTime(key, timestamp, creds, transaction, environment); - }); - } - - send_minKeyTime (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyTime_args(params); - try { - output.writeMessageBegin('minKeyTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyTime failed: unknown result'); - } - - minKeyTimestr (key, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyTimestr(key, timestamp, creds, transaction, environment); - }); - } - - send_minKeyTimestr (key, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyTimestr_args(params); - try { - output.writeMessageBegin('minKeyTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyTimestr failed: unknown result'); - } - - minKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_minKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_minKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_minKeyRecords_args(params); - try { - output.writeMessageBegin('minKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_minKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_minKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('minKeyRecords failed: unknown result'); - } - - navigateKeyRecord (key, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyRecord(key, record, creds, transaction, environment); - }); - } - - send_navigateKeyRecord (key, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyRecord_args(params); - try { - output.writeMessageBegin('navigateKeyRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyRecord failed: unknown result'); - } - - navigateKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyRecordTime(key, record, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyRecordTime (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyRecordTime_args(params); - try { - output.writeMessageBegin('navigateKeyRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyRecordTime failed: unknown result'); - } - - navigateKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyRecordTimestr(key, record, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyRecordTimestr (key, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyRecordTimestr_args(params); - try { - output.writeMessageBegin('navigateKeyRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyRecordTimestr failed: unknown result'); - } - - navigateKeysRecord (keys, record, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysRecord(keys, record, creds, transaction, environment); - }); - } - - send_navigateKeysRecord (keys, record, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysRecord_args(params); - try { - output.writeMessageBegin('navigateKeysRecord', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysRecord (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysRecord_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysRecord failed: unknown result'); - } - - navigateKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysRecordTime(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysRecordTime (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysRecordTime_args(params); - try { - output.writeMessageBegin('navigateKeysRecordTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysRecordTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysRecordTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysRecordTime failed: unknown result'); - } - - navigateKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysRecordTimestr(keys, record, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysRecordTimestr (keys, record, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - record: record, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysRecordTimestr_args(params); - try { - output.writeMessageBegin('navigateKeysRecordTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysRecordTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysRecordTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysRecordTimestr failed: unknown result'); - } - - navigateKeysRecords (keys, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysRecords(keys, records, creds, transaction, environment); - }); - } - - send_navigateKeysRecords (keys, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysRecords_args(params); - try { - output.writeMessageBegin('navigateKeysRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysRecords failed: unknown result'); - } - - navigateKeyRecords (key, records, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyRecords(key, records, creds, transaction, environment); - }); - } - - send_navigateKeyRecords (key, records, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyRecords_args(params); - try { - output.writeMessageBegin('navigateKeyRecords', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyRecords (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyRecords_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyRecords failed: unknown result'); - } - - navigateKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyRecordsTime(key, records, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyRecordsTime (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyRecordsTime_args(params); - try { - output.writeMessageBegin('navigateKeyRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyRecordsTime failed: unknown result'); - } - - navigateKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyRecordsTimestr(key, records, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyRecordsTimestr (key, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyRecordsTimestr_args(params); - try { - output.writeMessageBegin('navigateKeyRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyRecordsTimestr failed: unknown result'); - } - - navigateKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysRecordsTime(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysRecordsTime (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysRecordsTime_args(params); - try { - output.writeMessageBegin('navigateKeysRecordsTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysRecordsTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysRecordsTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysRecordsTime failed: unknown result'); - } - - navigateKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysRecordsTimestr(keys, records, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysRecordsTimestr (keys, records, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - records: records, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysRecordsTimestr_args(params); - try { - output.writeMessageBegin('navigateKeysRecordsTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysRecordsTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysRecordsTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysRecordsTimestr failed: unknown result'); - } - - navigateKeyCcl (key, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyCcl(key, ccl, creds, transaction, environment); - }); - } - - send_navigateKeyCcl (key, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyCcl_args(params); - try { - output.writeMessageBegin('navigateKeyCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyCcl failed: unknown result'); - } - - navigateKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyCclTime(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyCclTime (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyCclTime_args(params); - try { - output.writeMessageBegin('navigateKeyCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyCclTime failed: unknown result'); - } - - navigateKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyCclTimestr(key, ccl, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyCclTimestr (key, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyCclTimestr_args(params); - try { - output.writeMessageBegin('navigateKeyCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyCclTimestr failed: unknown result'); - } - - navigateKeysCcl (keys, ccl, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysCcl(keys, ccl, creds, transaction, environment); - }); - } - - send_navigateKeysCcl (keys, ccl, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysCcl_args(params); - try { - output.writeMessageBegin('navigateKeysCcl', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysCcl (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysCcl_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysCcl failed: unknown result'); - } - - navigateKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysCclTime(keys, ccl, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysCclTime (keys, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysCclTime_args(params); - try { - output.writeMessageBegin('navigateKeysCclTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysCclTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysCclTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysCclTime failed: unknown result'); - } - - navigateKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysCclTimestr(keys, ccl, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysCclTimestr (keys, ccl, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - ccl: ccl, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysCclTimestr_args(params); - try { - output.writeMessageBegin('navigateKeysCclTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysCclTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysCclTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysCclTimestr failed: unknown result'); - } - - navigateKeyCriteria (key, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyCriteria(key, criteria, creds, transaction, environment); - }); - } - - send_navigateKeyCriteria (key, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyCriteria_args(params); - try { - output.writeMessageBegin('navigateKeyCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyCriteria failed: unknown result'); - } - - navigateKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyCriteriaTime(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyCriteriaTime (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyCriteriaTime_args(params); - try { - output.writeMessageBegin('navigateKeyCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyCriteriaTime failed: unknown result'); - } - - navigateKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeyCriteriaTimestr(key, criteria, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeyCriteriaTimestr (key, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - key: key, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeyCriteriaTimestr_args(params); - try { - output.writeMessageBegin('navigateKeyCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeyCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeyCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeyCriteriaTimestr failed: unknown result'); - } - - navigateKeysCriteria (keys, criteria, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysCriteria(keys, criteria, creds, transaction, environment); - }); - } - - send_navigateKeysCriteria (keys, criteria, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysCriteria_args(params); - try { - output.writeMessageBegin('navigateKeysCriteria', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysCriteria (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysCriteria_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysCriteria failed: unknown result'); - } - - navigateKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysCriteriaTime(keys, criteria, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysCriteriaTime (keys, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysCriteriaTime_args(params); - try { - output.writeMessageBegin('navigateKeysCriteriaTime', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysCriteriaTime (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysCriteriaTime_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysCriteriaTime failed: unknown result'); - } - - navigateKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_navigateKeysCriteriaTimestr(keys, criteria, timestamp, creds, transaction, environment); - }); - } - - send_navigateKeysCriteriaTimestr (keys, criteria, timestamp, creds, transaction, environment) { - const output = new this.pClass(this.output); - const params = { - keys: keys, - criteria: criteria, - timestamp: timestamp, - creds: creds, - transaction: transaction, - environment: environment - }; - const args = new ConcourseService_navigateKeysCriteriaTimestr_args(params); - try { - output.writeMessageBegin('navigateKeysCriteriaTimestr', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_navigateKeysCriteriaTimestr (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_navigateKeysCriteriaTimestr_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('navigateKeysCriteriaTimestr failed: unknown result'); - } - - getServerEnvironment (creds, token, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getServerEnvironment(creds, token, environment); - }); - } - - send_getServerEnvironment (creds, token, environment) { - const output = new this.pClass(this.output); - const params = { - creds: creds, - token: token, - environment: environment - }; - const args = new ConcourseService_getServerEnvironment_args(params); - try { - output.writeMessageBegin('getServerEnvironment', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getServerEnvironment (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getServerEnvironment_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getServerEnvironment failed: unknown result'); - } - - getServerVersion () { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_getServerVersion(); - }); - } - - send_getServerVersion () { - const output = new this.pClass(this.output); - const args = new ConcourseService_getServerVersion_args(); - try { - output.writeMessageBegin('getServerVersion', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_getServerVersion (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_getServerVersion_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('getServerVersion failed: unknown result'); - } - - time (creds, token, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_time(creds, token, environment); - }); - } - - send_time (creds, token, environment) { - const output = new this.pClass(this.output); - const params = { - creds: creds, - token: token, - environment: environment - }; - const args = new ConcourseService_time_args(params); - try { - output.writeMessageBegin('time', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_time (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_time_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('time failed: unknown result'); - } - - timePhrase (phrase, creds, token, environment) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_timePhrase(phrase, creds, token, environment); - }); - } - - send_timePhrase (phrase, creds, token, environment) { - const output = new this.pClass(this.output); - const params = { - phrase: phrase, - creds: creds, - token: token, - environment: environment - }; - const args = new ConcourseService_timePhrase_args(params); - try { - output.writeMessageBegin('timePhrase', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_timePhrase (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_timePhrase_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.ex3) { - return callback(result.ex3); - } - if (null !== result.ex4) { - return callback(result.ex4); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('timePhrase failed: unknown result'); - } - - invokeManagement (method, params, creds) { - this._seqid = this.new_seqid(); - const self = this; - return new Promise((resolve, reject) => { - self._reqs[self.seqid()] = (error, result) => { - return error ? reject(error) : resolve(result); - }; - self.send_invokeManagement(method, params, creds); - }); - } - - send_invokeManagement (method, params, creds) { - const output = new this.pClass(this.output); - const params = { - method: method, - params: params, - creds: creds - }; - const args = new ConcourseService_invokeManagement_args(params); - try { - output.writeMessageBegin('invokeManagement', Thrift.MessageType.CALL, this.seqid()); - args.write(output); - output.writeMessageEnd(); - return this.output.flush(); - } - catch (e) { - delete this._reqs[this.seqid()]; - if (typeof output.reset === 'function') { - output.reset(); - } - throw e; - } - } - - recv_invokeManagement (input, mtype, rseqid) { - const callback = this._reqs[rseqid] || function() {}; - delete this._reqs[rseqid]; - if (mtype == Thrift.MessageType.EXCEPTION) { - const x = new Thrift.TApplicationException(); - x.read(input); - input.readMessageEnd(); - return callback(x); - } - const result = new ConcourseService_invokeManagement_result(); - result.read(input); - input.readMessageEnd(); - - if (null !== result.ex) { - return callback(result.ex); - } - if (null !== result.ex2) { - return callback(result.ex2); - } - if (null !== result.success) { - return callback(null, result.success); - } - return callback('invokeManagement failed: unknown result'); - } -}; -const ConcourseServiceProcessor = exports.Processor = class { - constructor(handler) { - this._handler = handler; - } - process (input, output) { - const r = input.readMessageBegin(); - if (this['process_' + r.fname]) { - return this['process_' + r.fname].call(this, r.rseqid, input, output); - } else { - input.skip(Thrift.Type.STRUCT); - input.readMessageEnd(); - const x = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN_METHOD, 'Unknown function ' + r.fname); - output.writeMessageBegin(r.fname, Thrift.MessageType.EXCEPTION, r.rseqid); - x.write(output); - output.writeMessageEnd(); - output.flush(); - } - } - process_abort (seqid, input, output) { - const args = new ConcourseService_abort_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.abort.length === 3) { - Promise.resolve(this._handler.abort.bind(this._handler)( - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_abort_result({success: result}); - output.writeMessageBegin("abort", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException) { - result = new ConcourseService_abort_result(err); - output.writeMessageBegin("abort", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("abort", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.abort(args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException) { - result_obj = new ConcourseService_abort_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("abort", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("abort", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_addKeyValue (seqid, input, output) { - const args = new ConcourseService_addKeyValue_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.addKeyValue.length === 5) { - Promise.resolve(this._handler.addKeyValue.bind(this._handler)( - args.key, - args.value, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_addKeyValue_result({success: result}); - output.writeMessageBegin("addKeyValue", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_addKeyValue_result(err); - output.writeMessageBegin("addKeyValue", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("addKeyValue", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.addKeyValue(args.key, args.value, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_addKeyValue_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("addKeyValue", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("addKeyValue", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_addKeyValueRecord (seqid, input, output) { - const args = new ConcourseService_addKeyValueRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.addKeyValueRecord.length === 6) { - Promise.resolve(this._handler.addKeyValueRecord.bind(this._handler)( - args.key, - args.value, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_addKeyValueRecord_result({success: result}); - output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_addKeyValueRecord_result(err); - output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.addKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_addKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("addKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_addKeyValueRecords (seqid, input, output) { - const args = new ConcourseService_addKeyValueRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.addKeyValueRecords.length === 6) { - Promise.resolve(this._handler.addKeyValueRecords.bind(this._handler)( - args.key, - args.value, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_addKeyValueRecords_result({success: result}); - output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_addKeyValueRecords_result(err); - output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.addKeyValueRecords(args.key, args.value, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_addKeyValueRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("addKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditRecord (seqid, input, output) { - const args = new ConcourseService_auditRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditRecord.length === 4) { - Promise.resolve(this._handler.auditRecord.bind(this._handler)( - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditRecord_result({success: result}); - output.writeMessageBegin("auditRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditRecord_result(err); - output.writeMessageBegin("auditRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditRecordStart (seqid, input, output) { - const args = new ConcourseService_auditRecordStart_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditRecordStart.length === 5) { - Promise.resolve(this._handler.auditRecordStart.bind(this._handler)( - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditRecordStart_result({success: result}); - output.writeMessageBegin("auditRecordStart", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditRecordStart_result(err); - output.writeMessageBegin("auditRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditRecordStart(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditRecordStartstr (seqid, input, output) { - const args = new ConcourseService_auditRecordStartstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditRecordStartstr.length === 5) { - Promise.resolve(this._handler.auditRecordStartstr.bind(this._handler)( - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditRecordStartstr_result({success: result}); - output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditRecordStartstr_result(err); - output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditRecordStartstr(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditRecordStartEnd (seqid, input, output) { - const args = new ConcourseService_auditRecordStartEnd_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditRecordStartEnd.length === 6) { - Promise.resolve(this._handler.auditRecordStartEnd.bind(this._handler)( - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditRecordStartEnd_result({success: result}); - output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditRecordStartEnd_result(err); - output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditRecordStartEnd(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditRecordStartstrEndstr (seqid, input, output) { - const args = new ConcourseService_auditRecordStartstrEndstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditRecordStartstrEndstr.length === 6) { - Promise.resolve(this._handler.auditRecordStartstrEndstr.bind(this._handler)( - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditRecordStartstrEndstr_result({success: result}); - output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditRecordStartstrEndstr_result(err); - output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditRecordStartstrEndstr(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditKeyRecord (seqid, input, output) { - const args = new ConcourseService_auditKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditKeyRecord.length === 5) { - Promise.resolve(this._handler.auditKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditKeyRecord_result({success: result}); - output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditKeyRecord_result(err); - output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditKeyRecordStart (seqid, input, output) { - const args = new ConcourseService_auditKeyRecordStart_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditKeyRecordStart.length === 6) { - Promise.resolve(this._handler.auditKeyRecordStart.bind(this._handler)( - args.key, - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditKeyRecordStart_result({success: result}); - output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditKeyRecordStart_result(err); - output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditKeyRecordStart(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditKeyRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditKeyRecordStartstr (seqid, input, output) { - const args = new ConcourseService_auditKeyRecordStartstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditKeyRecordStartstr.length === 6) { - Promise.resolve(this._handler.auditKeyRecordStartstr.bind(this._handler)( - args.key, - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditKeyRecordStartstr_result({success: result}); - output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditKeyRecordStartstr_result(err); - output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditKeyRecordStartstr(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditKeyRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditKeyRecordStartEnd (seqid, input, output) { - const args = new ConcourseService_auditKeyRecordStartEnd_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditKeyRecordStartEnd.length === 7) { - Promise.resolve(this._handler.auditKeyRecordStartEnd.bind(this._handler)( - args.key, - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditKeyRecordStartEnd_result({success: result}); - output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditKeyRecordStartEnd_result(err); - output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditKeyRecordStartEnd(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditKeyRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_auditKeyRecordStartstrEndstr (seqid, input, output) { - const args = new ConcourseService_auditKeyRecordStartstrEndstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.auditKeyRecordStartstrEndstr.length === 7) { - Promise.resolve(this._handler.auditKeyRecordStartstrEndstr.bind(this._handler)( - args.key, - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_auditKeyRecordStartstrEndstr_result({success: result}); - output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_auditKeyRecordStartstrEndstr_result(err); - output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.auditKeyRecordStartstrEndstr(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_auditKeyRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("auditKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_browseKey (seqid, input, output) { - const args = new ConcourseService_browseKey_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.browseKey.length === 4) { - Promise.resolve(this._handler.browseKey.bind(this._handler)( - args.key, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_browseKey_result({success: result}); - output.writeMessageBegin("browseKey", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_browseKey_result(err); - output.writeMessageBegin("browseKey", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKey", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.browseKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_browseKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("browseKey", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKey", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_browseKeys (seqid, input, output) { - const args = new ConcourseService_browseKeys_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.browseKeys.length === 4) { - Promise.resolve(this._handler.browseKeys.bind(this._handler)( - args.keys, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_browseKeys_result({success: result}); - output.writeMessageBegin("browseKeys", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_browseKeys_result(err); - output.writeMessageBegin("browseKeys", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeys", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.browseKeys(args.keys, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_browseKeys_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("browseKeys", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeys", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_browseKeyTime (seqid, input, output) { - const args = new ConcourseService_browseKeyTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.browseKeyTime.length === 5) { - Promise.resolve(this._handler.browseKeyTime.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_browseKeyTime_result({success: result}); - output.writeMessageBegin("browseKeyTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_browseKeyTime_result(err); - output.writeMessageBegin("browseKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.browseKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_browseKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("browseKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_browseKeyTimestr (seqid, input, output) { - const args = new ConcourseService_browseKeyTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.browseKeyTimestr.length === 5) { - Promise.resolve(this._handler.browseKeyTimestr.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_browseKeyTimestr_result({success: result}); - output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_browseKeyTimestr_result(err); - output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.browseKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_browseKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_browseKeysTime (seqid, input, output) { - const args = new ConcourseService_browseKeysTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.browseKeysTime.length === 5) { - Promise.resolve(this._handler.browseKeysTime.bind(this._handler)( - args.keys, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_browseKeysTime_result({success: result}); - output.writeMessageBegin("browseKeysTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_browseKeysTime_result(err); - output.writeMessageBegin("browseKeysTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeysTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.browseKeysTime(args.keys, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_browseKeysTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("browseKeysTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeysTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_browseKeysTimestr (seqid, input, output) { - const args = new ConcourseService_browseKeysTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.browseKeysTimestr.length === 5) { - Promise.resolve(this._handler.browseKeysTimestr.bind(this._handler)( - args.keys, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_browseKeysTimestr_result({success: result}); - output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_browseKeysTimestr_result(err); - output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.browseKeysTimestr(args.keys, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_browseKeysTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("browseKeysTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_chronologizeKeyRecord (seqid, input, output) { - const args = new ConcourseService_chronologizeKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.chronologizeKeyRecord.length === 5) { - Promise.resolve(this._handler.chronologizeKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_chronologizeKeyRecord_result({success: result}); - output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_chronologizeKeyRecord_result(err); - output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.chronologizeKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_chronologizeKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_chronologizeKeyRecordStart (seqid, input, output) { - const args = new ConcourseService_chronologizeKeyRecordStart_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.chronologizeKeyRecordStart.length === 6) { - Promise.resolve(this._handler.chronologizeKeyRecordStart.bind(this._handler)( - args.key, - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_chronologizeKeyRecordStart_result({success: result}); - output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_chronologizeKeyRecordStart_result(err); - output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.chronologizeKeyRecordStart(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_chronologizeKeyRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_chronologizeKeyRecordStartstr (seqid, input, output) { - const args = new ConcourseService_chronologizeKeyRecordStartstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.chronologizeKeyRecordStartstr.length === 6) { - Promise.resolve(this._handler.chronologizeKeyRecordStartstr.bind(this._handler)( - args.key, - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_chronologizeKeyRecordStartstr_result({success: result}); - output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_chronologizeKeyRecordStartstr_result(err); - output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.chronologizeKeyRecordStartstr(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_chronologizeKeyRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_chronologizeKeyRecordStartEnd (seqid, input, output) { - const args = new ConcourseService_chronologizeKeyRecordStartEnd_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.chronologizeKeyRecordStartEnd.length === 7) { - Promise.resolve(this._handler.chronologizeKeyRecordStartEnd.bind(this._handler)( - args.key, - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_chronologizeKeyRecordStartEnd_result({success: result}); - output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_chronologizeKeyRecordStartEnd_result(err); - output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.chronologizeKeyRecordStartEnd(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_chronologizeKeyRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_chronologizeKeyRecordStartstrEndstr (seqid, input, output) { - const args = new ConcourseService_chronologizeKeyRecordStartstrEndstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.chronologizeKeyRecordStartstrEndstr.length === 7) { - Promise.resolve(this._handler.chronologizeKeyRecordStartstrEndstr.bind(this._handler)( - args.key, - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result({success: result}); - output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result(err); - output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.chronologizeKeyRecordStartstrEndstr(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_chronologizeKeyRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("chronologizeKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_clearRecord (seqid, input, output) { - const args = new ConcourseService_clearRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.clearRecord.length === 4) { - Promise.resolve(this._handler.clearRecord.bind(this._handler)( - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_clearRecord_result({success: result}); - output.writeMessageBegin("clearRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_clearRecord_result(err); - output.writeMessageBegin("clearRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.clearRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_clearRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("clearRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_clearRecords (seqid, input, output) { - const args = new ConcourseService_clearRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.clearRecords.length === 4) { - Promise.resolve(this._handler.clearRecords.bind(this._handler)( - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_clearRecords_result({success: result}); - output.writeMessageBegin("clearRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_clearRecords_result(err); - output.writeMessageBegin("clearRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.clearRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_clearRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("clearRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_clearKeyRecord (seqid, input, output) { - const args = new ConcourseService_clearKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.clearKeyRecord.length === 5) { - Promise.resolve(this._handler.clearKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_clearKeyRecord_result({success: result}); - output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_clearKeyRecord_result(err); - output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.clearKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_clearKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_clearKeysRecord (seqid, input, output) { - const args = new ConcourseService_clearKeysRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.clearKeysRecord.length === 5) { - Promise.resolve(this._handler.clearKeysRecord.bind(this._handler)( - args.keys, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_clearKeysRecord_result({success: result}); - output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_clearKeysRecord_result(err); - output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.clearKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_clearKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_clearKeyRecords (seqid, input, output) { - const args = new ConcourseService_clearKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.clearKeyRecords.length === 5) { - Promise.resolve(this._handler.clearKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_clearKeyRecords_result({success: result}); - output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_clearKeyRecords_result(err); - output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.clearKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_clearKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_clearKeysRecords (seqid, input, output) { - const args = new ConcourseService_clearKeysRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.clearKeysRecords.length === 5) { - Promise.resolve(this._handler.clearKeysRecords.bind(this._handler)( - args.keys, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_clearKeysRecords_result({success: result}); - output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_clearKeysRecords_result(err); - output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.clearKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_clearKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("clearKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_commit (seqid, input, output) { - const args = new ConcourseService_commit_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.commit.length === 3) { - Promise.resolve(this._handler.commit.bind(this._handler)( - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_commit_result({success: result}); - output.writeMessageBegin("commit", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_commit_result(err); - output.writeMessageBegin("commit", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("commit", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.commit(args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_commit_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("commit", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("commit", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describe (seqid, input, output) { - const args = new ConcourseService_describe_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describe.length === 3) { - Promise.resolve(this._handler.describe.bind(this._handler)( - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describe_result({success: result}); - output.writeMessageBegin("describe", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describe_result(err); - output.writeMessageBegin("describe", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describe", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describe(args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describe_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describe", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describe", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeTime (seqid, input, output) { - const args = new ConcourseService_describeTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeTime.length === 4) { - Promise.resolve(this._handler.describeTime.bind(this._handler)( - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeTime_result({success: result}); - output.writeMessageBegin("describeTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeTime_result(err); - output.writeMessageBegin("describeTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeTime(args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeTimestr (seqid, input, output) { - const args = new ConcourseService_describeTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeTimestr.length === 4) { - Promise.resolve(this._handler.describeTimestr.bind(this._handler)( - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeTimestr_result({success: result}); - output.writeMessageBegin("describeTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeTimestr_result(err); - output.writeMessageBegin("describeTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeTimestr(args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeRecord (seqid, input, output) { - const args = new ConcourseService_describeRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeRecord.length === 4) { - Promise.resolve(this._handler.describeRecord.bind(this._handler)( - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeRecord_result({success: result}); - output.writeMessageBegin("describeRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeRecord_result(err); - output.writeMessageBegin("describeRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeRecordTime (seqid, input, output) { - const args = new ConcourseService_describeRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeRecordTime.length === 5) { - Promise.resolve(this._handler.describeRecordTime.bind(this._handler)( - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeRecordTime_result({success: result}); - output.writeMessageBegin("describeRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeRecordTime_result(err); - output.writeMessageBegin("describeRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeRecordTime(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeRecordTimestr (seqid, input, output) { - const args = new ConcourseService_describeRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeRecordTimestr.length === 5) { - Promise.resolve(this._handler.describeRecordTimestr.bind(this._handler)( - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeRecordTimestr_result({success: result}); - output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeRecordTimestr_result(err); - output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeRecordTimestr(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeRecords (seqid, input, output) { - const args = new ConcourseService_describeRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeRecords.length === 4) { - Promise.resolve(this._handler.describeRecords.bind(this._handler)( - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeRecords_result({success: result}); - output.writeMessageBegin("describeRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeRecords_result(err); - output.writeMessageBegin("describeRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeRecordsTime (seqid, input, output) { - const args = new ConcourseService_describeRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeRecordsTime.length === 5) { - Promise.resolve(this._handler.describeRecordsTime.bind(this._handler)( - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeRecordsTime_result({success: result}); - output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeRecordsTime_result(err); - output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeRecordsTime(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_describeRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_describeRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.describeRecordsTimestr.length === 5) { - Promise.resolve(this._handler.describeRecordsTimestr.bind(this._handler)( - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_describeRecordsTimestr_result({success: result}); - output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_describeRecordsTimestr_result(err); - output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.describeRecordsTimestr(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_describeRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("describeRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffRecordStart (seqid, input, output) { - const args = new ConcourseService_diffRecordStart_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffRecordStart.length === 5) { - Promise.resolve(this._handler.diffRecordStart.bind(this._handler)( - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffRecordStart_result({success: result}); - output.writeMessageBegin("diffRecordStart", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffRecordStart_result(err); - output.writeMessageBegin("diffRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffRecordStart(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffRecordStartstr (seqid, input, output) { - const args = new ConcourseService_diffRecordStartstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffRecordStartstr.length === 5) { - Promise.resolve(this._handler.diffRecordStartstr.bind(this._handler)( - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffRecordStartstr_result({success: result}); - output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffRecordStartstr_result(err); - output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffRecordStartstr(args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffRecordStartEnd (seqid, input, output) { - const args = new ConcourseService_diffRecordStartEnd_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffRecordStartEnd.length === 6) { - Promise.resolve(this._handler.diffRecordStartEnd.bind(this._handler)( - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffRecordStartEnd_result({success: result}); - output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffRecordStartEnd_result(err); - output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffRecordStartEnd(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffRecordStartstrEndstr (seqid, input, output) { - const args = new ConcourseService_diffRecordStartstrEndstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffRecordStartstrEndstr.length === 6) { - Promise.resolve(this._handler.diffRecordStartstrEndstr.bind(this._handler)( - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffRecordStartstrEndstr_result({success: result}); - output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffRecordStartstrEndstr_result(err); - output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffRecordStartstrEndstr(args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyRecordStart (seqid, input, output) { - const args = new ConcourseService_diffKeyRecordStart_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyRecordStart.length === 6) { - Promise.resolve(this._handler.diffKeyRecordStart.bind(this._handler)( - args.key, - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyRecordStart_result({success: result}); - output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyRecordStart_result(err); - output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyRecordStart(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyRecordStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStart", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyRecordStartstr (seqid, input, output) { - const args = new ConcourseService_diffKeyRecordStartstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyRecordStartstr.length === 6) { - Promise.resolve(this._handler.diffKeyRecordStartstr.bind(this._handler)( - args.key, - args.record, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyRecordStartstr_result({success: result}); - output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyRecordStartstr_result(err); - output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyRecordStartstr(args.key, args.record, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyRecordStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyRecordStartEnd (seqid, input, output) { - const args = new ConcourseService_diffKeyRecordStartEnd_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyRecordStartEnd.length === 7) { - Promise.resolve(this._handler.diffKeyRecordStartEnd.bind(this._handler)( - args.key, - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyRecordStartEnd_result({success: result}); - output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyRecordStartEnd_result(err); - output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyRecordStartEnd(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyRecordStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyRecordStartstrEndstr (seqid, input, output) { - const args = new ConcourseService_diffKeyRecordStartstrEndstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyRecordStartstrEndstr.length === 7) { - Promise.resolve(this._handler.diffKeyRecordStartstrEndstr.bind(this._handler)( - args.key, - args.record, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyRecordStartstrEndstr_result({success: result}); - output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyRecordStartstrEndstr_result(err); - output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyRecordStartstrEndstr(args.key, args.record, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyRecordStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyRecordStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyStart (seqid, input, output) { - const args = new ConcourseService_diffKeyStart_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyStart.length === 5) { - Promise.resolve(this._handler.diffKeyStart.bind(this._handler)( - args.key, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyStart_result({success: result}); - output.writeMessageBegin("diffKeyStart", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyStart_result(err); - output.writeMessageBegin("diffKeyStart", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStart", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyStart(args.key, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyStart_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyStart", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStart", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyStartstr (seqid, input, output) { - const args = new ConcourseService_diffKeyStartstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyStartstr.length === 5) { - Promise.resolve(this._handler.diffKeyStartstr.bind(this._handler)( - args.key, - args.start, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyStartstr_result({success: result}); - output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyStartstr_result(err); - output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyStartstr(args.key, args.start, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyStartstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStartstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyStartEnd (seqid, input, output) { - const args = new ConcourseService_diffKeyStartEnd_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyStartEnd.length === 6) { - Promise.resolve(this._handler.diffKeyStartEnd.bind(this._handler)( - args.key, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyStartEnd_result({success: result}); - output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyStartEnd_result(err); - output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyStartEnd(args.key, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyStartEnd_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStartEnd", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_diffKeyStartstrEndstr (seqid, input, output) { - const args = new ConcourseService_diffKeyStartstrEndstr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.diffKeyStartstrEndstr.length === 6) { - Promise.resolve(this._handler.diffKeyStartstrEndstr.bind(this._handler)( - args.key, - args.start, - args.tend, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_diffKeyStartstrEndstr_result({success: result}); - output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_diffKeyStartstrEndstr_result(err); - output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.diffKeyStartstrEndstr(args.key, args.start, args.tend, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_diffKeyStartstrEndstr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("diffKeyStartstrEndstr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_invokePlugin (seqid, input, output) { - const args = new ConcourseService_invokePlugin_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.invokePlugin.length === 6) { - Promise.resolve(this._handler.invokePlugin.bind(this._handler)( - args.id, - args.method, - args.params, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_invokePlugin_result({success: result}); - output.writeMessageBegin("invokePlugin", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_invokePlugin_result(err); - output.writeMessageBegin("invokePlugin", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("invokePlugin", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.invokePlugin(args.id, args.method, args.params, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_invokePlugin_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("invokePlugin", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("invokePlugin", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_login (seqid, input, output) { - const args = new ConcourseService_login_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.login.length === 3) { - Promise.resolve(this._handler.login.bind(this._handler)( - args.username, - args.password, - args.environment - )).then(result => { - const result_obj = new ConcourseService_login_result({success: result}); - output.writeMessageBegin("login", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_login_result(err); - output.writeMessageBegin("login", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("login", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.login(args.username, args.password, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_login_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("login", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("login", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_logout (seqid, input, output) { - const args = new ConcourseService_logout_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.logout.length === 2) { - Promise.resolve(this._handler.logout.bind(this._handler)( - args.token, - args.environment - )).then(result => { - const result_obj = new ConcourseService_logout_result({success: result}); - output.writeMessageBegin("logout", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_logout_result(err); - output.writeMessageBegin("logout", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("logout", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.logout(args.token, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_logout_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("logout", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("logout", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_stage (seqid, input, output) { - const args = new ConcourseService_stage_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.stage.length === 2) { - Promise.resolve(this._handler.stage.bind(this._handler)( - args.token, - args.environment - )).then(result => { - const result_obj = new ConcourseService_stage_result({success: result}); - output.writeMessageBegin("stage", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_stage_result(err); - output.writeMessageBegin("stage", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("stage", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.stage(args.token, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_stage_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("stage", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("stage", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_insertJson (seqid, input, output) { - const args = new ConcourseService_insertJson_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.insertJson.length === 4) { - Promise.resolve(this._handler.insertJson.bind(this._handler)( - args.json, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_insertJson_result({success: result}); - output.writeMessageBegin("insertJson", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_insertJson_result(err); - output.writeMessageBegin("insertJson", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("insertJson", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.insertJson(args.json, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_insertJson_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("insertJson", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("insertJson", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_insertJsonRecord (seqid, input, output) { - const args = new ConcourseService_insertJsonRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.insertJsonRecord.length === 5) { - Promise.resolve(this._handler.insertJsonRecord.bind(this._handler)( - args.json, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_insertJsonRecord_result({success: result}); - output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_insertJsonRecord_result(err); - output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.insertJsonRecord(args.json, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_insertJsonRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("insertJsonRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_insertJsonRecords (seqid, input, output) { - const args = new ConcourseService_insertJsonRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.insertJsonRecords.length === 5) { - Promise.resolve(this._handler.insertJsonRecords.bind(this._handler)( - args.json, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_insertJsonRecords_result({success: result}); - output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_insertJsonRecords_result(err); - output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.insertJsonRecords(args.json, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_insertJsonRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("insertJsonRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_removeKeyValueRecord (seqid, input, output) { - const args = new ConcourseService_removeKeyValueRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.removeKeyValueRecord.length === 6) { - Promise.resolve(this._handler.removeKeyValueRecord.bind(this._handler)( - args.key, - args.value, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_removeKeyValueRecord_result({success: result}); - output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_removeKeyValueRecord_result(err); - output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.removeKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_removeKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("removeKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_removeKeyValueRecords (seqid, input, output) { - const args = new ConcourseService_removeKeyValueRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.removeKeyValueRecords.length === 6) { - Promise.resolve(this._handler.removeKeyValueRecords.bind(this._handler)( - args.key, - args.value, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_removeKeyValueRecords_result({success: result}); - output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_removeKeyValueRecords_result(err); - output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.removeKeyValueRecords(args.key, args.value, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_removeKeyValueRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("removeKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_setKeyValueRecord (seqid, input, output) { - const args = new ConcourseService_setKeyValueRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.setKeyValueRecord.length === 6) { - Promise.resolve(this._handler.setKeyValueRecord.bind(this._handler)( - args.key, - args.value, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_setKeyValueRecord_result({success: result}); - output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_setKeyValueRecord_result(err); - output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.setKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_setKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("setKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_setKeyValue (seqid, input, output) { - const args = new ConcourseService_setKeyValue_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.setKeyValue.length === 5) { - Promise.resolve(this._handler.setKeyValue.bind(this._handler)( - args.key, - args.value, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_setKeyValue_result({success: result}); - output.writeMessageBegin("setKeyValue", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_setKeyValue_result(err); - output.writeMessageBegin("setKeyValue", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("setKeyValue", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.setKeyValue(args.key, args.value, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_setKeyValue_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("setKeyValue", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("setKeyValue", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_setKeyValueRecords (seqid, input, output) { - const args = new ConcourseService_setKeyValueRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.setKeyValueRecords.length === 6) { - Promise.resolve(this._handler.setKeyValueRecords.bind(this._handler)( - args.key, - args.value, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_setKeyValueRecords_result({success: result}); - output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_setKeyValueRecords_result(err); - output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.setKeyValueRecords(args.key, args.value, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_setKeyValueRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("setKeyValueRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_reconcileKeyRecordValues (seqid, input, output) { - const args = new ConcourseService_reconcileKeyRecordValues_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.reconcileKeyRecordValues.length === 6) { - Promise.resolve(this._handler.reconcileKeyRecordValues.bind(this._handler)( - args.key, - args.record, - args.values, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_reconcileKeyRecordValues_result({success: result}); - output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_reconcileKeyRecordValues_result(err); - output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.reconcileKeyRecordValues(args.key, args.record, args.values, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_reconcileKeyRecordValues_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("reconcileKeyRecordValues", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_inventory (seqid, input, output) { - const args = new ConcourseService_inventory_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.inventory.length === 3) { - Promise.resolve(this._handler.inventory.bind(this._handler)( - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_inventory_result({success: result}); - output.writeMessageBegin("inventory", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_inventory_result(err); - output.writeMessageBegin("inventory", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("inventory", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.inventory(args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_inventory_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("inventory", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("inventory", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectRecord (seqid, input, output) { - const args = new ConcourseService_selectRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectRecord.length === 4) { - Promise.resolve(this._handler.selectRecord.bind(this._handler)( - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectRecord_result({success: result}); - output.writeMessageBegin("selectRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectRecord_result(err); - output.writeMessageBegin("selectRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectRecords (seqid, input, output) { - const args = new ConcourseService_selectRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectRecords.length === 4) { - Promise.resolve(this._handler.selectRecords.bind(this._handler)( - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectRecords_result({success: result}); - output.writeMessageBegin("selectRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectRecords_result(err); - output.writeMessageBegin("selectRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectRecordTime (seqid, input, output) { - const args = new ConcourseService_selectRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectRecordTime.length === 5) { - Promise.resolve(this._handler.selectRecordTime.bind(this._handler)( - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectRecordTime_result({success: result}); - output.writeMessageBegin("selectRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectRecordTime_result(err); - output.writeMessageBegin("selectRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectRecordTime(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectRecordTimestr (seqid, input, output) { - const args = new ConcourseService_selectRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectRecordTimestr.length === 5) { - Promise.resolve(this._handler.selectRecordTimestr.bind(this._handler)( - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectRecordTimestr_result({success: result}); - output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectRecordTimestr_result(err); - output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectRecordTimestr(args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectRecordsTime (seqid, input, output) { - const args = new ConcourseService_selectRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectRecordsTime.length === 5) { - Promise.resolve(this._handler.selectRecordsTime.bind(this._handler)( - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectRecordsTime_result({success: result}); - output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectRecordsTime_result(err); - output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectRecordsTime(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_selectRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectRecordsTimestr.length === 5) { - Promise.resolve(this._handler.selectRecordsTimestr.bind(this._handler)( - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectRecordsTimestr_result({success: result}); - output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectRecordsTimestr_result(err); - output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectRecordsTimestr(args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyRecord (seqid, input, output) { - const args = new ConcourseService_selectKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyRecord.length === 5) { - Promise.resolve(this._handler.selectKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyRecord_result({success: result}); - output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyRecord_result(err); - output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_selectKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyRecordTime.length === 6) { - Promise.resolve(this._handler.selectKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyRecordTime_result({success: result}); - output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyRecordTime_result(err); - output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.selectKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyRecordTimestr_result(err); - output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysRecord (seqid, input, output) { - const args = new ConcourseService_selectKeysRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysRecord.length === 5) { - Promise.resolve(this._handler.selectKeysRecord.bind(this._handler)( - args.keys, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysRecord_result({success: result}); - output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysRecord_result(err); - output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysRecordTime (seqid, input, output) { - const args = new ConcourseService_selectKeysRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysRecordTime.length === 6) { - Promise.resolve(this._handler.selectKeysRecordTime.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysRecordTime_result({success: result}); - output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysRecordTime_result(err); - output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysRecordTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeysRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysRecordTimestr.length === 6) { - Promise.resolve(this._handler.selectKeysRecordTimestr.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysRecordTimestr_result({success: result}); - output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysRecordTimestr_result(err); - output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysRecords (seqid, input, output) { - const args = new ConcourseService_selectKeysRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysRecords.length === 5) { - Promise.resolve(this._handler.selectKeysRecords.bind(this._handler)( - args.keys, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysRecords_result({success: result}); - output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysRecords_result(err); - output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyRecords (seqid, input, output) { - const args = new ConcourseService_selectKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyRecords.length === 5) { - Promise.resolve(this._handler.selectKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyRecords_result({success: result}); - output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyRecords_result(err); - output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_selectKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.selectKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyRecordsTime_result({success: result}); - output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyRecordsTime_result(err); - output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.selectKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyRecordsTimestr_result(err); - output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysRecordsTime (seqid, input, output) { - const args = new ConcourseService_selectKeysRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysRecordsTime.length === 6) { - Promise.resolve(this._handler.selectKeysRecordsTime.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysRecordsTime_result({success: result}); - output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysRecordsTime_result(err); - output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeysRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysRecordsTimestr.length === 6) { - Promise.resolve(this._handler.selectKeysRecordsTimestr.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysRecordsTimestr_result({success: result}); - output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysRecordsTimestr_result(err); - output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectCriteria (seqid, input, output) { - const args = new ConcourseService_selectCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectCriteria.length === 4) { - Promise.resolve(this._handler.selectCriteria.bind(this._handler)( - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectCriteria_result({success: result}); - output.writeMessageBegin("selectCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectCriteria_result(err); - output.writeMessageBegin("selectCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectCriteria(args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectCcl (seqid, input, output) { - const args = new ConcourseService_selectCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectCcl.length === 4) { - Promise.resolve(this._handler.selectCcl.bind(this._handler)( - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectCcl_result({success: result}); - output.writeMessageBegin("selectCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectCcl_result(err); - output.writeMessageBegin("selectCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectCcl(args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectCriteriaTime (seqid, input, output) { - const args = new ConcourseService_selectCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectCriteriaTime.length === 5) { - Promise.resolve(this._handler.selectCriteriaTime.bind(this._handler)( - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectCriteriaTime_result({success: result}); - output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectCriteriaTime_result(err); - output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectCriteriaTime(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_selectCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectCriteriaTimestr.length === 5) { - Promise.resolve(this._handler.selectCriteriaTimestr.bind(this._handler)( - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectCriteriaTimestr_result({success: result}); - output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectCriteriaTimestr_result(err); - output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectCriteriaTimestr(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectCclTime (seqid, input, output) { - const args = new ConcourseService_selectCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectCclTime.length === 5) { - Promise.resolve(this._handler.selectCclTime.bind(this._handler)( - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectCclTime_result({success: result}); - output.writeMessageBegin("selectCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectCclTime_result(err); - output.writeMessageBegin("selectCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectCclTime(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectCclTimestr (seqid, input, output) { - const args = new ConcourseService_selectCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectCclTimestr.length === 5) { - Promise.resolve(this._handler.selectCclTimestr.bind(this._handler)( - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectCclTimestr_result({success: result}); - output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectCclTimestr_result(err); - output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectCclTimestr(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyCriteria (seqid, input, output) { - const args = new ConcourseService_selectKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyCriteria.length === 5) { - Promise.resolve(this._handler.selectKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyCriteria_result({success: result}); - output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyCriteria_result(err); - output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyCcl (seqid, input, output) { - const args = new ConcourseService_selectKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyCcl.length === 5) { - Promise.resolve(this._handler.selectKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyCcl_result({success: result}); - output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyCcl_result(err); - output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_selectKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.selectKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyCriteriaTime_result(err); - output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.selectKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyCriteriaTimestr_result(err); - output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyCclTime (seqid, input, output) { - const args = new ConcourseService_selectKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyCclTime.length === 6) { - Promise.resolve(this._handler.selectKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyCclTime_result({success: result}); - output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyCclTime_result(err); - output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.selectKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeyCclTimestr_result({success: result}); - output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeyCclTimestr_result(err); - output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysCriteria (seqid, input, output) { - const args = new ConcourseService_selectKeysCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysCriteria.length === 5) { - Promise.resolve(this._handler.selectKeysCriteria.bind(this._handler)( - args.keys, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysCriteria_result({success: result}); - output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysCriteria_result(err); - output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysCriteria(args.keys, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysCcl (seqid, input, output) { - const args = new ConcourseService_selectKeysCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysCcl.length === 5) { - Promise.resolve(this._handler.selectKeysCcl.bind(this._handler)( - args.keys, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysCcl_result({success: result}); - output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysCcl_result(err); - output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysCcl(args.keys, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysCriteriaTime (seqid, input, output) { - const args = new ConcourseService_selectKeysCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysCriteriaTime.length === 6) { - Promise.resolve(this._handler.selectKeysCriteriaTime.bind(this._handler)( - args.keys, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysCriteriaTime_result({success: result}); - output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysCriteriaTime_result(err); - output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysCriteriaTime(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeysCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.selectKeysCriteriaTimestr.bind(this._handler)( - args.keys, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysCriteriaTimestr_result({success: result}); - output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysCriteriaTimestr_result(err); - output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysCriteriaTimestr(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysCclTime (seqid, input, output) { - const args = new ConcourseService_selectKeysCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysCclTime.length === 6) { - Promise.resolve(this._handler.selectKeysCclTime.bind(this._handler)( - args.keys, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysCclTime_result({success: result}); - output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysCclTime_result(err); - output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysCclTime(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_selectKeysCclTimestr (seqid, input, output) { - const args = new ConcourseService_selectKeysCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.selectKeysCclTimestr.length === 6) { - Promise.resolve(this._handler.selectKeysCclTimestr.bind(this._handler)( - args.keys, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_selectKeysCclTimestr_result({success: result}); - output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_selectKeysCclTimestr_result(err); - output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.selectKeysCclTimestr(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_selectKeysCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("selectKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyRecord (seqid, input, output) { - const args = new ConcourseService_getKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyRecord.length === 5) { - Promise.resolve(this._handler.getKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyRecord_result({success: result}); - output.writeMessageBegin("getKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyRecord_result(err); - output.writeMessageBegin("getKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_getKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyRecordTime.length === 6) { - Promise.resolve(this._handler.getKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyRecordTime_result({success: result}); - output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyRecordTime_result(err); - output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_getKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.getKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyRecordTimestr_result(err); - output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysRecord (seqid, input, output) { - const args = new ConcourseService_getKeysRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysRecord.length === 5) { - Promise.resolve(this._handler.getKeysRecord.bind(this._handler)( - args.keys, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysRecord_result({success: result}); - output.writeMessageBegin("getKeysRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysRecord_result(err); - output.writeMessageBegin("getKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysRecordTime (seqid, input, output) { - const args = new ConcourseService_getKeysRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysRecordTime.length === 6) { - Promise.resolve(this._handler.getKeysRecordTime.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysRecordTime_result({success: result}); - output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysRecordTime_result(err); - output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysRecordTimestr (seqid, input, output) { - const args = new ConcourseService_getKeysRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysRecordTimestr.length === 6) { - Promise.resolve(this._handler.getKeysRecordTimestr.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysRecordTimestr_result({success: result}); - output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysRecordTimestr_result(err); - output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysRecords (seqid, input, output) { - const args = new ConcourseService_getKeysRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysRecords.length === 5) { - Promise.resolve(this._handler.getKeysRecords.bind(this._handler)( - args.keys, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysRecords_result({success: result}); - output.writeMessageBegin("getKeysRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysRecords_result(err); - output.writeMessageBegin("getKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyRecords (seqid, input, output) { - const args = new ConcourseService_getKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyRecords.length === 5) { - Promise.resolve(this._handler.getKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyRecords_result({success: result}); - output.writeMessageBegin("getKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyRecords_result(err); - output.writeMessageBegin("getKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_getKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.getKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyRecordsTime_result({success: result}); - output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyRecordsTime_result(err); - output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_getKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.getKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyRecordsTimestr_result(err); - output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysRecordsTime (seqid, input, output) { - const args = new ConcourseService_getKeysRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysRecordsTime.length === 6) { - Promise.resolve(this._handler.getKeysRecordsTime.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysRecordsTime_result({success: result}); - output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysRecordsTime_result(err); - output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_getKeysRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysRecordsTimestr.length === 6) { - Promise.resolve(this._handler.getKeysRecordsTimestr.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysRecordsTimestr_result({success: result}); - output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysRecordsTimestr_result(err); - output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyCriteria (seqid, input, output) { - const args = new ConcourseService_getKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyCriteria.length === 5) { - Promise.resolve(this._handler.getKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyCriteria_result({success: result}); - output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyCriteria_result(err); - output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getCriteria (seqid, input, output) { - const args = new ConcourseService_getCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getCriteria.length === 4) { - Promise.resolve(this._handler.getCriteria.bind(this._handler)( - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getCriteria_result({success: result}); - output.writeMessageBegin("getCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getCriteria_result(err); - output.writeMessageBegin("getCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getCriteria(args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getCcl (seqid, input, output) { - const args = new ConcourseService_getCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getCcl.length === 4) { - Promise.resolve(this._handler.getCcl.bind(this._handler)( - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getCcl_result({success: result}); - output.writeMessageBegin("getCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getCcl_result(err); - output.writeMessageBegin("getCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getCcl(args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getCriteriaTime (seqid, input, output) { - const args = new ConcourseService_getCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getCriteriaTime.length === 5) { - Promise.resolve(this._handler.getCriteriaTime.bind(this._handler)( - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getCriteriaTime_result({success: result}); - output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getCriteriaTime_result(err); - output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getCriteriaTime(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_getCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getCriteriaTimestr.length === 5) { - Promise.resolve(this._handler.getCriteriaTimestr.bind(this._handler)( - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getCriteriaTimestr_result({success: result}); - output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getCriteriaTimestr_result(err); - output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getCriteriaTimestr(args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getCclTime (seqid, input, output) { - const args = new ConcourseService_getCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getCclTime.length === 5) { - Promise.resolve(this._handler.getCclTime.bind(this._handler)( - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getCclTime_result({success: result}); - output.writeMessageBegin("getCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getCclTime_result(err); - output.writeMessageBegin("getCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getCclTime(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getCclTimestr (seqid, input, output) { - const args = new ConcourseService_getCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getCclTimestr.length === 5) { - Promise.resolve(this._handler.getCclTimestr.bind(this._handler)( - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getCclTimestr_result({success: result}); - output.writeMessageBegin("getCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getCclTimestr_result(err); - output.writeMessageBegin("getCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getCclTimestr(args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyCcl (seqid, input, output) { - const args = new ConcourseService_getKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyCcl.length === 5) { - Promise.resolve(this._handler.getKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyCcl_result({success: result}); - output.writeMessageBegin("getKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyCcl_result(err); - output.writeMessageBegin("getKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_getKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.getKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyCriteriaTime_result(err); - output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_getKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.getKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyCriteriaTimestr_result(err); - output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyCclTime (seqid, input, output) { - const args = new ConcourseService_getKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyCclTime.length === 6) { - Promise.resolve(this._handler.getKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyCclTime_result({success: result}); - output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyCclTime_result(err); - output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_getKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.getKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeyCclTimestr_result({success: result}); - output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeyCclTimestr_result(err); - output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysCriteria (seqid, input, output) { - const args = new ConcourseService_getKeysCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysCriteria.length === 5) { - Promise.resolve(this._handler.getKeysCriteria.bind(this._handler)( - args.keys, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysCriteria_result({success: result}); - output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysCriteria_result(err); - output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysCriteria(args.keys, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysCcl (seqid, input, output) { - const args = new ConcourseService_getKeysCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysCcl.length === 5) { - Promise.resolve(this._handler.getKeysCcl.bind(this._handler)( - args.keys, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysCcl_result({success: result}); - output.writeMessageBegin("getKeysCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysCcl_result(err); - output.writeMessageBegin("getKeysCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysCcl(args.keys, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysCriteriaTime (seqid, input, output) { - const args = new ConcourseService_getKeysCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysCriteriaTime.length === 6) { - Promise.resolve(this._handler.getKeysCriteriaTime.bind(this._handler)( - args.keys, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysCriteriaTime_result({success: result}); - output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysCriteriaTime_result(err); - output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysCriteriaTime(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_getKeysCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.getKeysCriteriaTimestr.bind(this._handler)( - args.keys, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysCriteriaTimestr_result({success: result}); - output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysCriteriaTimestr_result(err); - output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysCriteriaTimestr(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysCclTime (seqid, input, output) { - const args = new ConcourseService_getKeysCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysCclTime.length === 6) { - Promise.resolve(this._handler.getKeysCclTime.bind(this._handler)( - args.keys, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysCclTime_result({success: result}); - output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysCclTime_result(err); - output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysCclTime(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getKeysCclTimestr (seqid, input, output) { - const args = new ConcourseService_getKeysCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getKeysCclTimestr.length === 6) { - Promise.resolve(this._handler.getKeysCclTimestr.bind(this._handler)( - args.keys, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getKeysCclTimestr_result({success: result}); - output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getKeysCclTimestr_result(err); - output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getKeysCclTimestr(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getKeysCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_verifyKeyValueRecord (seqid, input, output) { - const args = new ConcourseService_verifyKeyValueRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.verifyKeyValueRecord.length === 6) { - Promise.resolve(this._handler.verifyKeyValueRecord.bind(this._handler)( - args.key, - args.value, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_verifyKeyValueRecord_result({success: result}); - output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_verifyKeyValueRecord_result(err); - output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.verifyKeyValueRecord(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_verifyKeyValueRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyKeyValueRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_verifyKeyValueRecordTime (seqid, input, output) { - const args = new ConcourseService_verifyKeyValueRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.verifyKeyValueRecordTime.length === 7) { - Promise.resolve(this._handler.verifyKeyValueRecordTime.bind(this._handler)( - args.key, - args.value, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_verifyKeyValueRecordTime_result({success: result}); - output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_verifyKeyValueRecordTime_result(err); - output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.verifyKeyValueRecordTime(args.key, args.value, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_verifyKeyValueRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyKeyValueRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_verifyKeyValueRecordTimestr (seqid, input, output) { - const args = new ConcourseService_verifyKeyValueRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.verifyKeyValueRecordTimestr.length === 7) { - Promise.resolve(this._handler.verifyKeyValueRecordTimestr.bind(this._handler)( - args.key, - args.value, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_verifyKeyValueRecordTimestr_result({success: result}); - output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_verifyKeyValueRecordTimestr_result(err); - output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.verifyKeyValueRecordTimestr(args.key, args.value, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_verifyKeyValueRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyKeyValueRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_jsonifyRecords (seqid, input, output) { - const args = new ConcourseService_jsonifyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.jsonifyRecords.length === 5) { - Promise.resolve(this._handler.jsonifyRecords.bind(this._handler)( - args.records, - args.identifier, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_jsonifyRecords_result({success: result}); - output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_jsonifyRecords_result(err); - output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.jsonifyRecords(args.records, args.identifier, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_jsonifyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("jsonifyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_jsonifyRecordsTime (seqid, input, output) { - const args = new ConcourseService_jsonifyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.jsonifyRecordsTime.length === 6) { - Promise.resolve(this._handler.jsonifyRecordsTime.bind(this._handler)( - args.records, - args.timestamp, - args.identifier, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_jsonifyRecordsTime_result({success: result}); - output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_jsonifyRecordsTime_result(err); - output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.jsonifyRecordsTime(args.records, args.timestamp, args.identifier, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_jsonifyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("jsonifyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_jsonifyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_jsonifyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.jsonifyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.jsonifyRecordsTimestr.bind(this._handler)( - args.records, - args.timestamp, - args.identifier, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_jsonifyRecordsTimestr_result({success: result}); - output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_jsonifyRecordsTimestr_result(err); - output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.jsonifyRecordsTimestr(args.records, args.timestamp, args.identifier, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_jsonifyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("jsonifyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findCriteria (seqid, input, output) { - const args = new ConcourseService_findCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findCriteria.length === 4) { - Promise.resolve(this._handler.findCriteria.bind(this._handler)( - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findCriteria_result({success: result}); - output.writeMessageBegin("findCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findCriteria_result(err); - output.writeMessageBegin("findCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findCriteria(args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findCcl (seqid, input, output) { - const args = new ConcourseService_findCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findCcl.length === 4) { - Promise.resolve(this._handler.findCcl.bind(this._handler)( - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findCcl_result({success: result}); - output.writeMessageBegin("findCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findCcl_result(err); - output.writeMessageBegin("findCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findCcl(args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findKeyOperatorValues (seqid, input, output) { - const args = new ConcourseService_findKeyOperatorValues_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findKeyOperatorValues.length === 6) { - Promise.resolve(this._handler.findKeyOperatorValues.bind(this._handler)( - args.key, - args.operator, - args.values, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findKeyOperatorValues_result({success: result}); - output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findKeyOperatorValues_result(err); - output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findKeyOperatorValues(args.key, args.operator, args.values, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findKeyOperatorValues_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorValues", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findKeyOperatorValuesTime (seqid, input, output) { - const args = new ConcourseService_findKeyOperatorValuesTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findKeyOperatorValuesTime.length === 7) { - Promise.resolve(this._handler.findKeyOperatorValuesTime.bind(this._handler)( - args.key, - args.operator, - args.values, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findKeyOperatorValuesTime_result({success: result}); - output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findKeyOperatorValuesTime_result(err); - output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findKeyOperatorValuesTime(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findKeyOperatorValuesTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorValuesTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findKeyOperatorValuesTimestr (seqid, input, output) { - const args = new ConcourseService_findKeyOperatorValuesTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findKeyOperatorValuesTimestr.length === 7) { - Promise.resolve(this._handler.findKeyOperatorValuesTimestr.bind(this._handler)( - args.key, - args.operator, - args.values, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findKeyOperatorValuesTimestr_result({success: result}); - output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findKeyOperatorValuesTimestr_result(err); - output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findKeyOperatorValuesTimestr(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findKeyOperatorValuesTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findKeyOperatorstrValues (seqid, input, output) { - const args = new ConcourseService_findKeyOperatorstrValues_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findKeyOperatorstrValues.length === 6) { - Promise.resolve(this._handler.findKeyOperatorstrValues.bind(this._handler)( - args.key, - args.operator, - args.values, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findKeyOperatorstrValues_result({success: result}); - output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findKeyOperatorstrValues_result(err); - output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findKeyOperatorstrValues(args.key, args.operator, args.values, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findKeyOperatorstrValues_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorstrValues", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findKeyOperatorstrValuesTime (seqid, input, output) { - const args = new ConcourseService_findKeyOperatorstrValuesTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findKeyOperatorstrValuesTime.length === 7) { - Promise.resolve(this._handler.findKeyOperatorstrValuesTime.bind(this._handler)( - args.key, - args.operator, - args.values, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findKeyOperatorstrValuesTime_result({success: result}); - output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findKeyOperatorstrValuesTime_result(err); - output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findKeyOperatorstrValuesTime(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findKeyOperatorstrValuesTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorstrValuesTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findKeyOperatorstrValuesTimestr (seqid, input, output) { - const args = new ConcourseService_findKeyOperatorstrValuesTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findKeyOperatorstrValuesTimestr.length === 7) { - Promise.resolve(this._handler.findKeyOperatorstrValuesTimestr.bind(this._handler)( - args.key, - args.operator, - args.values, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findKeyOperatorstrValuesTimestr_result({success: result}); - output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findKeyOperatorstrValuesTimestr_result(err); - output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findKeyOperatorstrValuesTimestr(args.key, args.operator, args.values, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findKeyOperatorstrValuesTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findKeyOperatorstrValuesTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_search (seqid, input, output) { - const args = new ConcourseService_search_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.search.length === 5) { - Promise.resolve(this._handler.search.bind(this._handler)( - args.key, - args.query, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_search_result({success: result}); - output.writeMessageBegin("search", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_search_result(err); - output.writeMessageBegin("search", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("search", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.search(args.key, args.query, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_search_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("search", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("search", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeysRecordsTime (seqid, input, output) { - const args = new ConcourseService_revertKeysRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeysRecordsTime.length === 6) { - Promise.resolve(this._handler.revertKeysRecordsTime.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeysRecordsTime_result({success: result}); - output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeysRecordsTime_result(err); - output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeysRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_revertKeysRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeysRecordsTimestr.length === 6) { - Promise.resolve(this._handler.revertKeysRecordsTimestr.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeysRecordsTimestr_result({success: result}); - output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeysRecordsTimestr_result(err); - output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeysRecordTime (seqid, input, output) { - const args = new ConcourseService_revertKeysRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeysRecordTime.length === 6) { - Promise.resolve(this._handler.revertKeysRecordTime.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeysRecordTime_result({success: result}); - output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeysRecordTime_result(err); - output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeysRecordTimestr (seqid, input, output) { - const args = new ConcourseService_revertKeysRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeysRecordTimestr.length === 6) { - Promise.resolve(this._handler.revertKeysRecordTimestr.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeysRecordTimestr_result({success: result}); - output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeysRecordTimestr_result(err); - output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_revertKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.revertKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeyRecordsTime_result({success: result}); - output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeyRecordsTime_result(err); - output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_revertKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.revertKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeyRecordsTimestr_result(err); - output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_revertKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeyRecordTime.length === 6) { - Promise.resolve(this._handler.revertKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeyRecordTime_result({success: result}); - output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeyRecordTime_result(err); - output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_revertKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_revertKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.revertKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.revertKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_revertKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_revertKeyRecordTimestr_result(err); - output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.revertKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_revertKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("revertKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_pingRecords (seqid, input, output) { - const args = new ConcourseService_pingRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.pingRecords.length === 4) { - Promise.resolve(this._handler.pingRecords.bind(this._handler)( - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_pingRecords_result({success: result}); - output.writeMessageBegin("pingRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_pingRecords_result(err); - output.writeMessageBegin("pingRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("pingRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.pingRecords(args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_pingRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("pingRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("pingRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_pingRecord (seqid, input, output) { - const args = new ConcourseService_pingRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.pingRecord.length === 4) { - Promise.resolve(this._handler.pingRecord.bind(this._handler)( - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_pingRecord_result({success: result}); - output.writeMessageBegin("pingRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_pingRecord_result(err); - output.writeMessageBegin("pingRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("pingRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.pingRecord(args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_pingRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("pingRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("pingRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_verifyAndSwap (seqid, input, output) { - const args = new ConcourseService_verifyAndSwap_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.verifyAndSwap.length === 7) { - Promise.resolve(this._handler.verifyAndSwap.bind(this._handler)( - args.key, - args.expected, - args.record, - args.replacement, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_verifyAndSwap_result({success: result}); - output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_verifyAndSwap_result(err); - output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.verifyAndSwap(args.key, args.expected, args.record, args.replacement, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_verifyAndSwap_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyAndSwap", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_verifyOrSet (seqid, input, output) { - const args = new ConcourseService_verifyOrSet_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.verifyOrSet.length === 6) { - Promise.resolve(this._handler.verifyOrSet.bind(this._handler)( - args.key, - args.value, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_verifyOrSet_result({success: result}); - output.writeMessageBegin("verifyOrSet", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_verifyOrSet_result(err); - output.writeMessageBegin("verifyOrSet", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyOrSet", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.verifyOrSet(args.key, args.value, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_verifyOrSet_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("verifyOrSet", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("verifyOrSet", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findOrAddKeyValue (seqid, input, output) { - const args = new ConcourseService_findOrAddKeyValue_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findOrAddKeyValue.length === 5) { - Promise.resolve(this._handler.findOrAddKeyValue.bind(this._handler)( - args.key, - args.value, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findOrAddKeyValue_result({success: result}); - output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findOrAddKeyValue_result(err); - output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findOrAddKeyValue(args.key, args.value, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.InvalidArgumentException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findOrAddKeyValue_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findOrAddKeyValue", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findOrInsertCriteriaJson (seqid, input, output) { - const args = new ConcourseService_findOrInsertCriteriaJson_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findOrInsertCriteriaJson.length === 5) { - Promise.resolve(this._handler.findOrInsertCriteriaJson.bind(this._handler)( - args.criteria, - args.json, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findOrInsertCriteriaJson_result({success: result}); - output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findOrInsertCriteriaJson_result(err); - output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findOrInsertCriteriaJson(args.criteria, args.json, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findOrInsertCriteriaJson_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findOrInsertCriteriaJson", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_findOrInsertCclJson (seqid, input, output) { - const args = new ConcourseService_findOrInsertCclJson_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.findOrInsertCclJson.length === 5) { - Promise.resolve(this._handler.findOrInsertCclJson.bind(this._handler)( - args.ccl, - args.json, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_findOrInsertCclJson_result({success: result}); - output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_findOrInsertCclJson_result(err); - output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.findOrInsertCclJson(args.ccl, args.json, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.DuplicateEntryException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_findOrInsertCclJson_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("findOrInsertCclJson", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyRecord (seqid, input, output) { - const args = new ConcourseService_sumKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyRecord.length === 5) { - Promise.resolve(this._handler.sumKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyRecord_result({success: result}); - output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyRecord_result(err); - output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_sumKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyRecordTime.length === 6) { - Promise.resolve(this._handler.sumKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyRecordTime_result({success: result}); - output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyRecordTime_result(err); - output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_sumKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.sumKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyRecordTimestr_result(err); - output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyRecords (seqid, input, output) { - const args = new ConcourseService_sumKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyRecords.length === 5) { - Promise.resolve(this._handler.sumKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyRecords_result({success: result}); - output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyRecords_result(err); - output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_sumKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.sumKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyRecordsTime_result({success: result}); - output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyRecordsTime_result(err); - output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_sumKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.sumKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyRecordsTimestr_result(err); - output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKey (seqid, input, output) { - const args = new ConcourseService_sumKey_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKey.length === 4) { - Promise.resolve(this._handler.sumKey.bind(this._handler)( - args.key, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKey_result({success: result}); - output.writeMessageBegin("sumKey", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKey_result(err); - output.writeMessageBegin("sumKey", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKey", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKey", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKey", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyTime (seqid, input, output) { - const args = new ConcourseService_sumKeyTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyTime.length === 5) { - Promise.resolve(this._handler.sumKeyTime.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyTime_result({success: result}); - output.writeMessageBegin("sumKeyTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyTime_result(err); - output.writeMessageBegin("sumKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyTimestr (seqid, input, output) { - const args = new ConcourseService_sumKeyTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyTimestr.length === 5) { - Promise.resolve(this._handler.sumKeyTimestr.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyTimestr_result({success: result}); - output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyTimestr_result(err); - output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyCriteria (seqid, input, output) { - const args = new ConcourseService_sumKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyCriteria.length === 5) { - Promise.resolve(this._handler.sumKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyCriteria_result({success: result}); - output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyCriteria_result(err); - output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_sumKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.sumKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyCriteriaTime_result(err); - output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_sumKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.sumKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyCriteriaTimestr_result(err); - output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyCcl (seqid, input, output) { - const args = new ConcourseService_sumKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyCcl.length === 5) { - Promise.resolve(this._handler.sumKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyCcl_result({success: result}); - output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyCcl_result(err); - output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyCclTime (seqid, input, output) { - const args = new ConcourseService_sumKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyCclTime.length === 6) { - Promise.resolve(this._handler.sumKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyCclTime_result({success: result}); - output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyCclTime_result(err); - output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_sumKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_sumKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.sumKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.sumKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_sumKeyCclTimestr_result({success: result}); - output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_sumKeyCclTimestr_result(err); - output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.sumKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_sumKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("sumKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyRecord (seqid, input, output) { - const args = new ConcourseService_averageKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyRecord.length === 5) { - Promise.resolve(this._handler.averageKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyRecord_result({success: result}); - output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyRecord_result(err); - output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_averageKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyRecordTime.length === 6) { - Promise.resolve(this._handler.averageKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyRecordTime_result({success: result}); - output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyRecordTime_result(err); - output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_averageKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.averageKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyRecordTimestr_result(err); - output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyRecords (seqid, input, output) { - const args = new ConcourseService_averageKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyRecords.length === 5) { - Promise.resolve(this._handler.averageKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyRecords_result({success: result}); - output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyRecords_result(err); - output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_averageKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.averageKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyRecordsTime_result({success: result}); - output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyRecordsTime_result(err); - output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_averageKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.averageKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyRecordsTimestr_result(err); - output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKey (seqid, input, output) { - const args = new ConcourseService_averageKey_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKey.length === 4) { - Promise.resolve(this._handler.averageKey.bind(this._handler)( - args.key, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKey_result({success: result}); - output.writeMessageBegin("averageKey", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKey_result(err); - output.writeMessageBegin("averageKey", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKey", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKey", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKey", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyTime (seqid, input, output) { - const args = new ConcourseService_averageKeyTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyTime.length === 5) { - Promise.resolve(this._handler.averageKeyTime.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyTime_result({success: result}); - output.writeMessageBegin("averageKeyTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyTime_result(err); - output.writeMessageBegin("averageKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyTimestr (seqid, input, output) { - const args = new ConcourseService_averageKeyTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyTimestr.length === 5) { - Promise.resolve(this._handler.averageKeyTimestr.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyTimestr_result({success: result}); - output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyTimestr_result(err); - output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyCriteria (seqid, input, output) { - const args = new ConcourseService_averageKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyCriteria.length === 5) { - Promise.resolve(this._handler.averageKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyCriteria_result({success: result}); - output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyCriteria_result(err); - output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_averageKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.averageKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyCriteriaTime_result(err); - output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_averageKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.averageKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyCriteriaTimestr_result(err); - output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyCcl (seqid, input, output) { - const args = new ConcourseService_averageKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyCcl.length === 5) { - Promise.resolve(this._handler.averageKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyCcl_result({success: result}); - output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyCcl_result(err); - output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyCclTime (seqid, input, output) { - const args = new ConcourseService_averageKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyCclTime.length === 6) { - Promise.resolve(this._handler.averageKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyCclTime_result({success: result}); - output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyCclTime_result(err); - output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_averageKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_averageKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.averageKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.averageKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_averageKeyCclTimestr_result({success: result}); - output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_averageKeyCclTimestr_result(err); - output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.averageKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_averageKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("averageKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyRecord (seqid, input, output) { - const args = new ConcourseService_countKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyRecord.length === 5) { - Promise.resolve(this._handler.countKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyRecord_result({success: result}); - output.writeMessageBegin("countKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyRecord_result(err); - output.writeMessageBegin("countKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_countKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyRecordTime.length === 6) { - Promise.resolve(this._handler.countKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyRecordTime_result({success: result}); - output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyRecordTime_result(err); - output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_countKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.countKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyRecordTimestr_result(err); - output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyRecords (seqid, input, output) { - const args = new ConcourseService_countKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyRecords.length === 5) { - Promise.resolve(this._handler.countKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyRecords_result({success: result}); - output.writeMessageBegin("countKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyRecords_result(err); - output.writeMessageBegin("countKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_countKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.countKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyRecordsTime_result({success: result}); - output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyRecordsTime_result(err); - output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_countKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.countKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyRecordsTimestr_result(err); - output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKey (seqid, input, output) { - const args = new ConcourseService_countKey_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKey.length === 4) { - Promise.resolve(this._handler.countKey.bind(this._handler)( - args.key, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKey_result({success: result}); - output.writeMessageBegin("countKey", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKey_result(err); - output.writeMessageBegin("countKey", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKey", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKey", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKey", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyTime (seqid, input, output) { - const args = new ConcourseService_countKeyTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyTime.length === 5) { - Promise.resolve(this._handler.countKeyTime.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyTime_result({success: result}); - output.writeMessageBegin("countKeyTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyTime_result(err); - output.writeMessageBegin("countKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyTimestr (seqid, input, output) { - const args = new ConcourseService_countKeyTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyTimestr.length === 5) { - Promise.resolve(this._handler.countKeyTimestr.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyTimestr_result({success: result}); - output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyTimestr_result(err); - output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyCriteria (seqid, input, output) { - const args = new ConcourseService_countKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyCriteria.length === 5) { - Promise.resolve(this._handler.countKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyCriteria_result({success: result}); - output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyCriteria_result(err); - output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_countKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.countKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyCriteriaTime_result(err); - output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_countKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.countKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyCriteriaTimestr_result(err); - output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyCcl (seqid, input, output) { - const args = new ConcourseService_countKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyCcl.length === 5) { - Promise.resolve(this._handler.countKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyCcl_result({success: result}); - output.writeMessageBegin("countKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyCcl_result(err); - output.writeMessageBegin("countKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyCclTime (seqid, input, output) { - const args = new ConcourseService_countKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyCclTime.length === 6) { - Promise.resolve(this._handler.countKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyCclTime_result({success: result}); - output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyCclTime_result(err); - output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_countKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_countKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.countKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.countKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_countKeyCclTimestr_result({success: result}); - output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_countKeyCclTimestr_result(err); - output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.countKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_countKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("countKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyRecord (seqid, input, output) { - const args = new ConcourseService_maxKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyRecord.length === 5) { - Promise.resolve(this._handler.maxKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyRecord_result({success: result}); - output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyRecord_result(err); - output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_maxKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyRecordTime.length === 6) { - Promise.resolve(this._handler.maxKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyRecordTime_result({success: result}); - output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyRecordTime_result(err); - output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_maxKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.maxKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyRecordTimestr_result(err); - output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyRecords (seqid, input, output) { - const args = new ConcourseService_maxKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyRecords.length === 5) { - Promise.resolve(this._handler.maxKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyRecords_result({success: result}); - output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyRecords_result(err); - output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_maxKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.maxKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyRecordsTime_result({success: result}); - output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyRecordsTime_result(err); - output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_maxKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.maxKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyRecordsTimestr_result(err); - output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyCriteria (seqid, input, output) { - const args = new ConcourseService_maxKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyCriteria.length === 5) { - Promise.resolve(this._handler.maxKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyCriteria_result({success: result}); - output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyCriteria_result(err); - output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_maxKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.maxKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyCriteriaTime_result(err); - output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_maxKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.maxKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyCriteriaTimestr_result(err); - output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyCcl (seqid, input, output) { - const args = new ConcourseService_maxKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyCcl.length === 5) { - Promise.resolve(this._handler.maxKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyCcl_result({success: result}); - output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyCcl_result(err); - output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyCclTime (seqid, input, output) { - const args = new ConcourseService_maxKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyCclTime.length === 6) { - Promise.resolve(this._handler.maxKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyCclTime_result({success: result}); - output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyCclTime_result(err); - output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_maxKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.maxKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyCclTimestr_result({success: result}); - output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyCclTimestr_result(err); - output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKey (seqid, input, output) { - const args = new ConcourseService_maxKey_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKey.length === 4) { - Promise.resolve(this._handler.maxKey.bind(this._handler)( - args.key, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKey_result({success: result}); - output.writeMessageBegin("maxKey", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKey_result(err); - output.writeMessageBegin("maxKey", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKey", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKey", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKey", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyTime (seqid, input, output) { - const args = new ConcourseService_maxKeyTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyTime.length === 5) { - Promise.resolve(this._handler.maxKeyTime.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyTime_result({success: result}); - output.writeMessageBegin("maxKeyTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyTime_result(err); - output.writeMessageBegin("maxKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_maxKeyTimestr (seqid, input, output) { - const args = new ConcourseService_maxKeyTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.maxKeyTimestr.length === 5) { - Promise.resolve(this._handler.maxKeyTimestr.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_maxKeyTimestr_result({success: result}); - output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_maxKeyTimestr_result(err); - output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.maxKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_maxKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("maxKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyRecord (seqid, input, output) { - const args = new ConcourseService_minKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyRecord.length === 5) { - Promise.resolve(this._handler.minKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyRecord_result({success: result}); - output.writeMessageBegin("minKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyRecord_result(err); - output.writeMessageBegin("minKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_minKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyRecordTime.length === 6) { - Promise.resolve(this._handler.minKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyRecordTime_result({success: result}); - output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyRecordTime_result(err); - output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_minKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.minKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyRecordTimestr_result(err); - output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKey (seqid, input, output) { - const args = new ConcourseService_minKey_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKey.length === 4) { - Promise.resolve(this._handler.minKey.bind(this._handler)( - args.key, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKey_result({success: result}); - output.writeMessageBegin("minKey", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKey_result(err); - output.writeMessageBegin("minKey", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKey", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKey(args.key, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKey_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKey", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKey", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_minKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.minKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyRecordsTime_result({success: result}); - output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyRecordsTime_result(err); - output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_minKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.minKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyRecordsTimestr_result(err); - output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyCriteria (seqid, input, output) { - const args = new ConcourseService_minKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyCriteria.length === 5) { - Promise.resolve(this._handler.minKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyCriteria_result({success: result}); - output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyCriteria_result(err); - output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_minKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.minKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyCriteriaTime_result(err); - output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_minKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.minKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyCriteriaTimestr_result(err); - output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyCcl (seqid, input, output) { - const args = new ConcourseService_minKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyCcl.length === 5) { - Promise.resolve(this._handler.minKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyCcl_result({success: result}); - output.writeMessageBegin("minKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyCcl_result(err); - output.writeMessageBegin("minKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyCclTime (seqid, input, output) { - const args = new ConcourseService_minKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyCclTime.length === 6) { - Promise.resolve(this._handler.minKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyCclTime_result({success: result}); - output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyCclTime_result(err); - output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_minKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.minKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyCclTimestr_result({success: result}); - output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyCclTimestr_result(err); - output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyTime (seqid, input, output) { - const args = new ConcourseService_minKeyTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyTime.length === 5) { - Promise.resolve(this._handler.minKeyTime.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyTime_result({success: result}); - output.writeMessageBegin("minKeyTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyTime_result(err); - output.writeMessageBegin("minKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyTime(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyTimestr (seqid, input, output) { - const args = new ConcourseService_minKeyTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyTimestr.length === 5) { - Promise.resolve(this._handler.minKeyTimestr.bind(this._handler)( - args.key, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyTimestr_result({success: result}); - output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyTimestr_result(err); - output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyTimestr(args.key, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_minKeyRecords (seqid, input, output) { - const args = new ConcourseService_minKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.minKeyRecords.length === 5) { - Promise.resolve(this._handler.minKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_minKeyRecords_result({success: result}); - output.writeMessageBegin("minKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_minKeyRecords_result(err); - output.writeMessageBegin("minKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.minKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_minKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("minKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("minKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyRecord (seqid, input, output) { - const args = new ConcourseService_navigateKeyRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyRecord.length === 5) { - Promise.resolve(this._handler.navigateKeyRecord.bind(this._handler)( - args.key, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyRecord_result({success: result}); - output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyRecord_result(err); - output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyRecord(args.key, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyRecordTime (seqid, input, output) { - const args = new ConcourseService_navigateKeyRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyRecordTime.length === 6) { - Promise.resolve(this._handler.navigateKeyRecordTime.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyRecordTime_result({success: result}); - output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyRecordTime_result(err); - output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyRecordTime(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyRecordTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeyRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyRecordTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeyRecordTimestr.bind(this._handler)( - args.key, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyRecordTimestr_result({success: result}); - output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyRecordTimestr_result(err); - output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyRecordTimestr(args.key, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysRecord (seqid, input, output) { - const args = new ConcourseService_navigateKeysRecord_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysRecord.length === 5) { - Promise.resolve(this._handler.navigateKeysRecord.bind(this._handler)( - args.keys, - args.record, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysRecord_result({success: result}); - output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysRecord_result(err); - output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysRecord(args.keys, args.record, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysRecord_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecord", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysRecordTime (seqid, input, output) { - const args = new ConcourseService_navigateKeysRecordTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysRecordTime.length === 6) { - Promise.resolve(this._handler.navigateKeysRecordTime.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysRecordTime_result({success: result}); - output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysRecordTime_result(err); - output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysRecordTime(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysRecordTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysRecordTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeysRecordTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysRecordTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeysRecordTimestr.bind(this._handler)( - args.keys, - args.record, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysRecordTimestr_result({success: result}); - output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysRecordTimestr_result(err); - output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysRecordTimestr(args.keys, args.record, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysRecordTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysRecords (seqid, input, output) { - const args = new ConcourseService_navigateKeysRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysRecords.length === 5) { - Promise.resolve(this._handler.navigateKeysRecords.bind(this._handler)( - args.keys, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysRecords_result({success: result}); - output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysRecords_result(err); - output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysRecords(args.keys, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyRecords (seqid, input, output) { - const args = new ConcourseService_navigateKeyRecords_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyRecords.length === 5) { - Promise.resolve(this._handler.navigateKeyRecords.bind(this._handler)( - args.key, - args.records, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyRecords_result({success: result}); - output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyRecords_result(err); - output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyRecords(args.key, args.records, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyRecords_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecords", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyRecordsTime (seqid, input, output) { - const args = new ConcourseService_navigateKeyRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyRecordsTime.length === 6) { - Promise.resolve(this._handler.navigateKeyRecordsTime.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyRecordsTime_result({success: result}); - output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyRecordsTime_result(err); - output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyRecordsTime(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeyRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyRecordsTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeyRecordsTimestr.bind(this._handler)( - args.key, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyRecordsTimestr_result({success: result}); - output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyRecordsTimestr_result(err); - output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyRecordsTimestr(args.key, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysRecordsTime (seqid, input, output) { - const args = new ConcourseService_navigateKeysRecordsTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysRecordsTime.length === 6) { - Promise.resolve(this._handler.navigateKeysRecordsTime.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysRecordsTime_result({success: result}); - output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysRecordsTime_result(err); - output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysRecordsTime(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysRecordsTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordsTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysRecordsTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeysRecordsTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysRecordsTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeysRecordsTimestr.bind(this._handler)( - args.keys, - args.records, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysRecordsTimestr_result({success: result}); - output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysRecordsTimestr_result(err); - output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysRecordsTimestr(args.keys, args.records, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysRecordsTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysRecordsTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyCcl (seqid, input, output) { - const args = new ConcourseService_navigateKeyCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyCcl.length === 5) { - Promise.resolve(this._handler.navigateKeyCcl.bind(this._handler)( - args.key, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyCcl_result({success: result}); - output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyCcl_result(err); - output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyCcl(args.key, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyCclTime (seqid, input, output) { - const args = new ConcourseService_navigateKeyCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyCclTime.length === 6) { - Promise.resolve(this._handler.navigateKeyCclTime.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyCclTime_result({success: result}); - output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyCclTime_result(err); - output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyCclTime(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyCclTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeyCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyCclTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeyCclTimestr.bind(this._handler)( - args.key, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyCclTimestr_result({success: result}); - output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyCclTimestr_result(err); - output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyCclTimestr(args.key, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysCcl (seqid, input, output) { - const args = new ConcourseService_navigateKeysCcl_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysCcl.length === 5) { - Promise.resolve(this._handler.navigateKeysCcl.bind(this._handler)( - args.keys, - args.ccl, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysCcl_result({success: result}); - output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysCcl_result(err); - output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysCcl(args.keys, args.ccl, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysCcl_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCcl", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysCclTime (seqid, input, output) { - const args = new ConcourseService_navigateKeysCclTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysCclTime.length === 6) { - Promise.resolve(this._handler.navigateKeysCclTime.bind(this._handler)( - args.keys, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysCclTime_result({success: result}); - output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysCclTime_result(err); - output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysCclTime(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysCclTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCclTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysCclTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeysCclTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysCclTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeysCclTimestr.bind(this._handler)( - args.keys, - args.ccl, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysCclTimestr_result({success: result}); - output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysCclTimestr_result(err); - output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysCclTimestr(args.keys, args.ccl, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysCclTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCclTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyCriteria (seqid, input, output) { - const args = new ConcourseService_navigateKeyCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyCriteria.length === 5) { - Promise.resolve(this._handler.navigateKeyCriteria.bind(this._handler)( - args.key, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyCriteria_result({success: result}); - output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyCriteria_result(err); - output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyCriteria(args.key, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyCriteriaTime (seqid, input, output) { - const args = new ConcourseService_navigateKeyCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyCriteriaTime.length === 6) { - Promise.resolve(this._handler.navigateKeyCriteriaTime.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyCriteriaTime_result({success: result}); - output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyCriteriaTime_result(err); - output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyCriteriaTime(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeyCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeyCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeyCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeyCriteriaTimestr.bind(this._handler)( - args.key, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeyCriteriaTimestr_result({success: result}); - output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeyCriteriaTimestr_result(err); - output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeyCriteriaTimestr(args.key, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeyCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeyCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysCriteria (seqid, input, output) { - const args = new ConcourseService_navigateKeysCriteria_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysCriteria.length === 5) { - Promise.resolve(this._handler.navigateKeysCriteria.bind(this._handler)( - args.keys, - args.criteria, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysCriteria_result({success: result}); - output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysCriteria_result(err); - output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysCriteria(args.keys, args.criteria, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysCriteria_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCriteria", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysCriteriaTime (seqid, input, output) { - const args = new ConcourseService_navigateKeysCriteriaTime_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysCriteriaTime.length === 6) { - Promise.resolve(this._handler.navigateKeysCriteriaTime.bind(this._handler)( - args.keys, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysCriteriaTime_result({success: result}); - output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysCriteriaTime_result(err); - output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysCriteriaTime(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysCriteriaTime_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCriteriaTime", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_navigateKeysCriteriaTimestr (seqid, input, output) { - const args = new ConcourseService_navigateKeysCriteriaTimestr_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.navigateKeysCriteriaTimestr.length === 6) { - Promise.resolve(this._handler.navigateKeysCriteriaTimestr.bind(this._handler)( - args.keys, - args.criteria, - args.timestamp, - args.creds, - args.transaction, - args.environment - )).then(result => { - const result_obj = new ConcourseService_navigateKeysCriteriaTimestr_result({success: result}); - output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_navigateKeysCriteriaTimestr_result(err); - output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.navigateKeysCriteriaTimestr(args.keys, args.criteria, args.timestamp, args.creds, args.transaction, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_navigateKeysCriteriaTimestr_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("navigateKeysCriteriaTimestr", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getServerEnvironment (seqid, input, output) { - const args = new ConcourseService_getServerEnvironment_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getServerEnvironment.length === 3) { - Promise.resolve(this._handler.getServerEnvironment.bind(this._handler)( - args.creds, - args.token, - args.environment - )).then(result => { - const result_obj = new ConcourseService_getServerEnvironment_result({success: result}); - output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getServerEnvironment_result(err); - output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getServerEnvironment(args.creds, args.token, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getServerEnvironment_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getServerEnvironment", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_getServerVersion (seqid, input, output) { - const args = new ConcourseService_getServerVersion_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.getServerVersion.length === 0) { - Promise.resolve(this._handler.getServerVersion.bind(this._handler)( - )).then(result => { - const result_obj = new ConcourseService_getServerVersion_result({success: result}); - output.writeMessageBegin("getServerVersion", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_getServerVersion_result(err); - output.writeMessageBegin("getServerVersion", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getServerVersion", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.getServerVersion((err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_getServerVersion_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("getServerVersion", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("getServerVersion", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_time (seqid, input, output) { - const args = new ConcourseService_time_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.time.length === 3) { - Promise.resolve(this._handler.time.bind(this._handler)( - args.creds, - args.token, - args.environment - )).then(result => { - const result_obj = new ConcourseService_time_result({success: result}); - output.writeMessageBegin("time", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_time_result(err); - output.writeMessageBegin("time", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("time", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.time(args.creds, args.token, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_time_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("time", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("time", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_timePhrase (seqid, input, output) { - const args = new ConcourseService_timePhrase_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.timePhrase.length === 4) { - Promise.resolve(this._handler.timePhrase.bind(this._handler)( - args.phrase, - args.creds, - args.token, - args.environment - )).then(result => { - const result_obj = new ConcourseService_timePhrase_result({success: result}); - output.writeMessageBegin("timePhrase", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result = new ConcourseService_timePhrase_result(err); - output.writeMessageBegin("timePhrase", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("timePhrase", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.timePhrase(args.phrase, args.creds, args.token, args.environment, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.TransactionException || err instanceof exceptions_ttypes.ParseException || err instanceof exceptions_ttypes.PermissionException) { - result_obj = new ConcourseService_timePhrase_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("timePhrase", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("timePhrase", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } - process_invokeManagement (seqid, input, output) { - const args = new ConcourseService_invokeManagement_args(); - args.read(input); - input.readMessageEnd(); - if (this._handler.invokeManagement.length === 3) { - Promise.resolve(this._handler.invokeManagement.bind(this._handler)( - args.method, - args.params, - args.creds - )).then(result => { - const result_obj = new ConcourseService_invokeManagement_result({success: result}); - output.writeMessageBegin("invokeManagement", Thrift.MessageType.REPLY, seqid); - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }).catch(err => { - let result; - if (err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.ManagementException) { - result = new ConcourseService_invokeManagement_result(err); - output.writeMessageBegin("invokeManagement", Thrift.MessageType.REPLY, seqid); - } else { - result = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("invokeManagement", Thrift.MessageType.EXCEPTION, seqid); - } - result.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } else { - this._handler.invokeManagement(args.method, args.params, args.creds, (err, result) => { - let result_obj; - if ((err === null || typeof err === 'undefined') || err instanceof exceptions_ttypes.SecurityException || err instanceof exceptions_ttypes.ManagementException) { - result_obj = new ConcourseService_invokeManagement_result((err !== null || typeof err === 'undefined') ? err : {success: result}); - output.writeMessageBegin("invokeManagement", Thrift.MessageType.REPLY, seqid); - } else { - result_obj = new Thrift.TApplicationException(Thrift.TApplicationExceptionType.UNKNOWN, err.message); - output.writeMessageBegin("invokeManagement", Thrift.MessageType.EXCEPTION, seqid); - } - result_obj.write(output); - output.writeMessageEnd(); - output.flush(); - }); - } - } -}; diff --git a/concourse-driver-node-js/src/thrift/concourse_types.js b/concourse-driver-node-js/src/thrift/concourse_types.js index 34642b7451..66eec08934 100644 --- a/concourse-driver-node-js/src/thrift/concourse_types.js +++ b/concourse-driver-node-js/src/thrift/concourse_types.js @@ -5,6 +5,8 @@ // "use strict"; +const buffer = require('buffer'); +const Buffer = buffer.Buffer; const thrift = require('thrift'); const Thrift = thrift.Thrift; diff --git a/concourse-driver-node-js/src/utilities/convert.js b/concourse-driver-node-js/src/utilities/convert.js index 0f1ee16e32..4966429168 100644 --- a/concourse-driver-node-js/src/utilities/convert.js +++ b/concourse-driver-node-js/src/utilities/convert.js @@ -1,18 +1,182 @@ 'use strict' +const _$isArray = require('lodash/isArray') +const _$isBoolean = require('lodash/isBoolean') +const _$isInteger = require('lodash/isInteger') const _$isMap = require('lodash/isMap') -// const _$isPlainObject = require('lodash/isPlainObject') -// const _$mapValues = require('lodash/mapValues') -// const _$toPairs = require('lodash/toPairs') -// const concourseThriftDataTypes = require('../thrift/data_types') - -class Convert { - static javascriptify(thriftData) { - if (_$isMap(thriftData)) { - // const result = new Map() - // // - // // - // return result +const _$isNull = require('lodash/isNull') +const _$isNumber = require('lodash/isNumber') +const _$isString = require('lodash/isString') +const _$map = require('lodash/map') +const BN = require('bn.js') +const buffer = require('buffer') +const concourseThriftDataTypes = require('../thrift/data_types') +const concourseThriftSharedTypes = require('../thrift/shared_types') +const Link = require('../link') +const Long = require('../long') +const luxon = require('luxon') +const Tag = require('../tag') + +const { Buffer } = buffer +const { DateTime } = luxon + +const Convert = {} + +Convert.javascriptify = function javascriptify(thriftData) { + if (_$isMap(thriftData)) { + const result = new Map() + for (let [ thriftDataKey, thriftDataValue ] of thriftData) { + const dataKey = Convert.javascriptify(thriftDataKey) + const dataValue = Convert.javascriptify(thriftDataValue) + result.set(dataKey, dataValue) + } + return result + } else if (_$isArray(thriftData)) { + return _$map(thriftData, (dataValue) => { + return Convert.javascriptify(dataValue) + }) + } else if (thriftData instanceof concourseThriftDataTypes.TObject) { + return Convert.tobjectToJavascript(thriftData) + } else { + return thriftData + } +} + +Convert.javascriptToTobject = function javascriptToTobject(object) { + if (_$isNull(object)) { + return new concourseThriftDataTypes.TObject({ + data: Buffer.alloc(0), + type: concourseThriftSharedTypes.Type.NULL + }) + } else if (_$isBoolean(object)) { + const boolean = object + const booleanBuffer = Buffer.alloc(1) + booleanBuffer.writeUInt8(boolean ? 1 : 0) + return new concourseThriftDataTypes.TObject({ + data: booleanBuffer, + type: concourseThriftSharedTypes.Type.BOOLEAN + }) + } else if (Link.isLink(object)) { + const link = object + const { buffer: linkBuffer } = link + return new concourseThriftDataTypes.TObject({ + data: linkBuffer, + type: concourseThriftSharedTypes.Type.LINK + }) + } else if (Long.isLong(object)) { + const long = object + const { buffer: longBuffer } = long + return new concourseThriftDataTypes.TObject({ + data: longBuffer, + type: concourseThriftSharedTypes.Type.LONG + }) + } else if (_$isNumber(object)) { + const number = object + if (_$isInteger(number)) { + const integerBuffer = Buffer.alloc(4) + integerBuffer.writeInt32BE(number) + return new concourseThriftDataTypes.TObject({ + data: integerBuffer, + type: concourseThriftSharedTypes.Type.INTEGER + }) + } else { + const doubleBuffer = Buffer.alloc(8) + doubleBuffer.writeDoubleBE(number) + return new concourseThriftDataTypes.TObject({ + data: doubleBuffer, + type: concourseThriftSharedTypes.Type.DOUBLE + }) + } + } else if (Tag.isTag(object)) { + const tag = object + const tagString = String(tag) + const tagBuffer = Buffer.from(tagString, 'utf8') + return new concourseThriftDataTypes.TObject({ + data: tagBuffer, + type: concourseThriftSharedTypes.Type.TAG + }) + } else if (_$isString(object)) { + const string = object + const stringBuffer = Buffer.from(string, 'utf8') + return new concourseThriftDataTypes.TObject({ + data: stringBuffer, + type: concourseThriftSharedTypes.Type.STRING + }) + } else if (DateTime.isDateTime(object)) { + const dateTime = object + const millisecondTimestamp = dateTime.toMillis() + const millisecondTimestampBigNumber = new BN(millisecondTimestamp, 10, 'be') + const microsecondTimestampBigNumber = millisecondTimestampBigNumber.mul( + new BN(1000, 10, 'be')) + const microsecondTimestamp = Long( + microsecondTimestampBigNumber.toString('hex')) + const { buffer: microsecondTimestampBuffer } = microsecondTimestamp + return new concourseThriftDataTypes.TObject({ + data: microsecondTimestampBuffer, + type: concourseThriftSharedTypes.Type.TIMESTAMP + }) + } +} + +Convert.thriftify = function thriftify(object) { + if (_$isMap(object)) { + const mapData = object + const result = new Map() + for (let [ mapDatumKey, mapDatumValue ] of mapData) { + const datumKey = Convert.thriftify(mapDatumKey) + const datumValue = Convert.thriftify(mapDatumValue) + result.set(datumKey, datumValue) + } + return result + } else if (_$isArray(object)) { + const arrayData = object + return _$map(arrayData, (datum) => { + return Convert.thriftify(datum) + }) + } else if (! (object instanceof concourseThriftDataTypes.TObject)) { + return Convert.javascriptToTobject(object) + } else { + const data = object + return data + } +} + +Convert.tobjectToJavascript = function tobjectToJavascript(tobject) { + switch (tobject.type) { + case concourseThriftSharedTypes.Type.BOOLEAN: { + const value = tobject.data.readUInt8(0) + return (value === 1) ? true : false + } + case concourseThriftSharedTypes.Type.DOUBLE: { + return tobject.data.readDoubleBE(0) + } + case concourseThriftSharedTypes.Type.FLOAT: { + return tobject.data.readFloatBE(0) + } + case concourseThriftSharedTypes.Type.INTEGER: { + return tobject.data.readInt32BE(0) + } + case concourseThriftSharedTypes.Type.LINK: { + const record = Long(tobject.data) + return Link.to(record) + } + case concourseThriftSharedTypes.Type.LONG: { + return Long(tobject.data) + } + case concourseThriftSharedTypes.Type.NULL: { + return null + } + case concourseThriftSharedTypes.Type.STRING: { + return tobject.data.toString('utf8') + } + case concourseThriftSharedTypes.Type.TAG: { + const value = tobject.data.toString('utf8') + return Tag.create(value) + } + case concourseThriftSharedTypes.Type.TIMESTAMP: { + const microsecondTimestamp = Long(tobject.data) + const millisecondTimestamp = (microsecondTimestamp / 1000) // TODO(@jonathanmarvens): Figure out a way to do this without losing any bits. + return DateTime.fromMillis(millisecondTimestamp, { zone: 'utc' }) } } } diff --git a/concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js b/concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js index 41df01949a..78f494198c 100755 --- a/concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js +++ b/concourse-driver-node-js/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js @@ -55,7 +55,6 @@ const processFile = (thriftFilePath, javascriptFilePath, thriftSource, javascrip return } if (methodResultClassesToCheck.has(pathIdPath.node.name)) { - console.log(`In method result class "${pathIdPath.node.name}"`) path .get('init', 'body', 'body') .each((path) => { @@ -67,9 +66,7 @@ const processFile = (thriftFilePath, javascriptFilePath, thriftSource, javascrip return } if (pathKeyPath.node.name === 'read') { - console.log(` > In method "read" of method result class "${pathIdPath.node.name}"`) const emptyObjectAssignmentsFound = {} - const mapVariableNames = new Set() const readMethodBlockPath = path.get('value', 'body', 'body') astTypes.visit(readMethodBlockPath.node, { visitAssignmentExpression(path) { @@ -93,6 +90,7 @@ const processFile = (thriftFilePath, javascriptFilePath, thriftSource, javascrip this.traverse(path) } }) + const mapVariableNames = new Set() astTypes.visit(readMethodBlockPath.node, { visitCallExpression(path) { try { @@ -129,14 +127,26 @@ const processFile = (thriftFilePath, javascriptFilePath, thriftSource, javascrip astTypes.visit(readMethodBlockPath.node, { visitMemberExpression(path) { try { - debugger - // const { code: memberExpressionValue } = recast.print(path.node) const pathObjectPath = path.get('object') const { code: memberExpressionValue } = recast.print(pathObjectPath.node) - // if () { - // this.abort() - // } - console.log(`memberExpressionValue === ${memberExpressionValue}`) + if (! mapVariableNames.has(memberExpressionValue)) { + this.abort() + } + const { parentPath: pathParentPath } = path + if (! astTypes.namedTypes.AssignmentExpression.check(pathParentPath.node)) { + this.abort() + } + const pathParentPathLeftPath = pathParentPath.get('left') + const pathParentPathRightPath = pathParentPath.get('right') + pathParentPath.replace( + astTypes.builders.callExpression( + astTypes.builders.memberExpression(pathObjectPath.node, + astTypes.builders.identifier('set'), + false), + [ + pathParentPathLeftPath.node.property, + pathParentPathRightPath.node + ])) } catch (error) { if (error instanceof this.AbortRequest) { return false @@ -147,10 +157,8 @@ const processFile = (thriftFilePath, javascriptFilePath, thriftSource, javascrip this.traverse(path) } }) - // } }) - console.log('\n') } }) } diff --git a/utils/compile-thrift-node-js.sh b/utils/compile-thrift-node-js.sh index f5b0843fa0..d56d4da99c 100755 --- a/utils/compile-thrift-node-js.sh +++ b/utils/compile-thrift-node-js.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash -# Copyright (c) 2015 Cinchapi Inc. +# Copyright (c) 2019 Cinchapi Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -23,6 +23,12 @@ PACKAGE=$TARGET"/src/thrift" cd $THRIFT_DIR +if [ -d $PACKAGE ]; then + rm -fr $PACKAGE +fi + +mkdir -p $PACKAGE + # Run the thrift compile thrift --gen js:es6,node -out $PACKAGE -recurse concourse.thrift @@ -31,10 +37,12 @@ if [ $? -ne 0 ]; then fi # Patch the `NULL` type in the "concourse_types.js" file with a `data` property so that it validates properly. -perl -e 's#^(var\sthrift\s=\srequire\('"'"'thrift'"'"'\);)$#var buffer = require('"'"'buffer'"'"');\nvar Buffer = buffer.Buffer;\n$1#m' -i -p $PACKAGE"/concourse_types.js" +perl -e 's#^(const\sthrift\s=\srequire\('"'"'thrift'"'"'\);)$#const buffer = require('"'"'buffer'"'"');\nconst Buffer = buffer.Buffer;\n$1#m' -i -p $PACKAGE"/concourse_types.js" perl -e 's#^(\s{2}'"'"'type'"'"'\s:\s9)$# '"'"'data'"'"' : Buffer.alloc(0),\n$1#m' -i -p $PACKAGE"/concourse_types.js" + +# Run the code transformers. $TARGET"/tools/thrift-transformers/remove-server-code.js" $PACKAGE"/ConcourseService.js" -# $TARGET"/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js" $TARGET"/../interface/concourse.thrift" $PACKAGE"/ConcourseService.js" +$TARGET"/tools/thrift-transformers/thrift-map-return-types-to-javascript-maps.js" $TARGET"/../interface/concourse.thrift" $PACKAGE"/ConcourseService.js" echo "Finished compiling the Thrift API for Node.js to "$(cd $PACKAGE && pwd)